mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-25 22:01:30 +00:00
Bug 1037128 - Regression: Contact API usage is being prompt on webpages r=fabrice
This commit is contained in:
parent
8b1b2270f8
commit
dbe64e615e
@ -248,10 +248,16 @@ ContactManager.prototype = {
|
||||
let permValue =
|
||||
Services.perms.testExactPermissionFromPrincipal(principal, type);
|
||||
if (permValue == Ci.nsIPermissionManager.ALLOW_ACTION) {
|
||||
aAllowCallback();
|
||||
if (aAllowCallback) {
|
||||
aAllowCallback();
|
||||
}
|
||||
return;
|
||||
} else if (permValue == Ci.nsIPermissionManager.DENY_ACTION ||
|
||||
permValue == Ci.nsIPermissionManager.UNKNOWN_ACTION) {
|
||||
if (aCancelCallback) {
|
||||
aCancelCallback();
|
||||
}
|
||||
return;
|
||||
} else if (permValue == Ci.nsIPermissionManager.DENY_ACTION) {
|
||||
aCancelCallback();
|
||||
}
|
||||
|
||||
// Create an array with a single nsIContentPermissionType element.
|
||||
@ -425,7 +431,7 @@ ContactManager.prototype = {
|
||||
}.bind(this);
|
||||
|
||||
let cancelCallback = function() {
|
||||
Services.DOMRequest.fireError(request);
|
||||
Services.DOMRequest.fireError(request, "");
|
||||
};
|
||||
|
||||
this.askPermission("revision", request, allowCallback, cancelCallback);
|
||||
@ -442,7 +448,7 @@ ContactManager.prototype = {
|
||||
}.bind(this);
|
||||
|
||||
let cancelCallback = function() {
|
||||
Services.DOMRequest.fireError(request);
|
||||
Services.DOMRequest.fireError(request, "");
|
||||
};
|
||||
|
||||
this.askPermission("count", request, allowCallback, cancelCallback);
|
||||
|
@ -5,11 +5,14 @@ skip-if = e10s
|
||||
[test_contacts_basics.html]
|
||||
skip-if = (toolkit == 'gonk' && debug) #debug-only failure
|
||||
[test_contacts_basics2.html]
|
||||
skip-if = (toolkit == 'gonk' && debug) #debug-only failure
|
||||
[test_contacts_blobs.html]
|
||||
skip-if = (toolkit == 'gonk' && debug) #debug-only failure
|
||||
[test_contacts_events.html]
|
||||
[test_contacts_getall.html]
|
||||
skip-if = (toolkit == 'gonk' && debug) #debug-only failure
|
||||
[test_contacts_getall2.html]
|
||||
skip-if = (toolkit == 'gonk' && debug) #debug-only failure
|
||||
[test_contacts_international.html]
|
||||
[test_contacts_substringmatching.html]
|
||||
[test_contacts_substringmatchingVE.html]
|
||||
|
Loading…
Reference in New Issue
Block a user