Skip to content

Commit

Permalink
[screenshare] Fix startViewer error handling
Browse files Browse the repository at this point in the history
  • Loading branch information
prlanzarin committed Oct 25, 2020
1 parent 6521402 commit 10bd154
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions lib/screenshare/screenshare.js
Original file line number Diff line number Diff line change
Expand Up @@ -676,11 +676,10 @@ module.exports = class Screenshare extends BaseProvider {
this._getFullViewerLogMetadata(connectionId));

return resolve(sdpAnswer);
}
catch (err) {
Logger.error(LOG_PREFIX, `Viewer subscribe failed for ${userId} due to ${err.message}`,
{ ...this._getFullViewerLogMetadata(id), error: this._handleError(LOG_PREFIX, err) });
return reject(this._handleError(LOG_PREFIX, err));
} catch (error) {
Logger.error(LOG_PREFIX, `Viewer subscribe failed for ${userId} due to ${error.message}`,
{ ...this._getFullViewerLogMetadata(connectionId), error: this._handleError(LOG_PREFIX, error) });
return reject(this._handleError(LOG_PREFIX, error));
}
});
}
Expand Down

0 comments on commit 10bd154

Please sign in to comment.