Implemented a workaround for certain devices dropping connection after digest authentication challege in connection requests.
This commit is contained in:
1 parent
305558f186
commit
74008bc7de
1 file changed
+3
@@ -117,6 +117,9 @@ connectionRequest = (deviceId, callback) ->
|
||||
authString = auth.digest(username, password, uri.path, 'GET', null, authHeader)
|
||||
|
||||
conReq(connectionRequestUrl, authString, (statusCode, authHeader) ->
|
||||
if statusCode == 0
|
||||
# Workaround for some devices unexpectedly closing the connection
|
||||
return conReq(connectionRequestUrl, authString, (statusCode) -> callback(statusToError(statusCode)))
|
||||
callback(statusToError(statusCode))
|
||||
)
|
||||
else
|
||||
|
||||
Reference in new issue
Block a user