Improved logging when put operation failed

CURA-1036
This commit is contained in:
Jaime van Kessel 2016-06-17 13:00:05 +02:00
parent 0b9af6055c
commit be779cb92a

View file

@ -256,7 +256,7 @@ class NetworkPrinterOutputDevice(PrinterOutputDevice):
if reply.attribute(QNetworkRequest.HttpStatusCodeAttribute) == 204:
pass # Request was sucesfull!
else:
Logger.log("d","Something went wrong when trying to update data of API. %s", reply.readAll())
Logger.log("d","Something went wrong when trying to update data of API. %s statuscode: %s", reply.readAll(), reply.attribute(QNetworkRequest.HttpStatusCodeAttribute))
else:
Logger.log("d", "NetworkPrinterOutputDevice got an unhandled operation %s", reply.operation())