Update connector.js

Add a 500 err code upon empty resp if error