Skip to content
This repository has been archived by the owner on Nov 3, 2021. It is now read-only.

Commit

Permalink
Merge pull request #23 from schien/bug1277197-fix-js-error-in-ui-glue
Browse files Browse the repository at this point in the history
Bug 1277197 - fix JS error in PresentationRequestUIGlue for 2-UAs device. r=kuoe0. a=jocheng
  • Loading branch information
xeonchen committed Jun 1, 2016
2 parents 1342028 + db22618 commit f50a49e
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion b2g/components/PresentationRequestUIGlue.js
Expand Up @@ -23,7 +23,11 @@ function PresentationRequestUIGlue() { }
PresentationRequestUIGlue.prototype = {

sendRequest: function(aUrl, aSessionId, aDevice) {
let localDevice = aDevice.QueryInterface(Ci.nsIPresentationLocalDevice);
let localDevice;
try {
localDevice = aDevice.QueryInterface(Ci.nsIPresentationLocalDevice);
} catch (e) {}

if (localDevice) {
return this.sendTo1UA(aUrl, aSessionId, localDevice.windowId);
} else {
Expand Down

0 comments on commit f50a49e

Please sign in to comment.