Only display read error in verbose mode

This commit is contained in:
shortcutme 2017-08-09 14:19:56 +02:00
parent b503d59c49
commit ef4a4acbc0
No known key found for this signature in database
GPG key ID: 5B63BAE6CB9613AE

View file

@ -229,7 +229,8 @@ class FileRequest(object):
self.log.debug("GetFile %s %s request error: %s" % (self.connection, params["inner_path"], Debug.formatException(err)))
self.response({"error": "File read error: %s" % err})
except Exception, err:
self.log.debug("GetFile read error: %s" % Debug.formatException(err))
if config.verbose:
self.log.debug("GetFile read error: %s" % Debug.formatException(err))
self.response({"error": "File read error"})
return False