Escaping apostrophes

This commit is contained in:
Max Bassett 2016-08-10 15:12:26 -04:00 committed by GitHub
parent f121af93c3
commit 906aff19ef

View File

@ -92,7 +92,7 @@ To add the app that uses this plugin to the device's battery optimization whitel
window.powerManagement.addAppToBatteryWhitelist(function() {
console.log('A dialog has popped up asking you to accept adding the app to the whitelist.');
}, function() {
console.log('Failed to add the app to the device's battery optimization whitelist.');
console.log('Failed to add the app to the device\'s battery optimization whitelist.');
});
```
@ -104,10 +104,10 @@ To check to see if the app that uses this plugin is on the device's battery opti
```js
window.powerManagement.isIgnoringBatteryOptimizations(function(result) {
if (result === 1) {
console.log('This app IS on the device's battery optimization whitelist.');
console.log('This app IS on the device\'s battery optimization whitelist.');
}
else {
console.log('This app IS NOT on the device's battery optimization whitelist.');
console.log('This app IS NOT on the device\'s battery optimization whitelist.');
}
}, function() {
console.log('Failed to add the app to the device's battery optimization whitelist.');
@ -122,14 +122,14 @@ window.powerManagement.isIgnoringBatteryOptimizations(function(result) {
window.powerManagement.addAppToBatteryWhitelist(function() {
console.log('A dialog has popped up asking you to accept adding the app to the whitelist.');
}, function() {
console.log('Failed to add the app to the device's battery optimization whitelist.');
console.log('Failed to add the app to the device\'s battery optimization whitelist.');
});
}
else {
console.log('This app IS NOT on the device's battery optimization whitelist.');
console.log('This app IS NOT on the device\'s battery optimization whitelist.');
}
}, function() {
console.log('Failed to add the app to the device's battery optimization whitelist.');
console.log('Failed to add the app to the device\'s battery optimization whitelist.');
});
```
Note that in all the above examples, all callbacks are optional.