Fixed! On andrew's suggestion, verified that chrome uses chrome.runtime.lastError and replaced all errors  to use it 
(Except for WebAuthFlowDetails creation with invalid parameters. Chrome throws an exception here and so I have left that particular 'throw'  in the code)