function workerReserve() {
  navigator.budget.reserve('silent-push').then(function(reserved) {
    if (reserved)
      sendMessageToClients('message', 'ok - reserved budget');
    else
      sendMessageToClients('message', 'failed - not able to reserve budget');
  }, function() {
    sendMessageToClients('message',
        'failed - error while trying to reserve budget');
  });
}
// Request a reservation for a silent push.
Request a reservation for a silent push.
Request a reservation for a silent push .
function workerReserve() {
  navigator.budget.reserve('silent-push').then(function(reserved) {
    if (reserved)
      sendMessageToClients('message', 'ok - reserved budget');
    else
      sendMessageToClients('message', 'failed - not able to reserve budget');
  }, function() {
    sendMessageToClients('message',
        'failed - error while trying to reserve budget');
  });
}
function workerReserve ( ) { navigator . budget . reserve ( 'silent-push' ) . then ( function ( reserved ) { if ( reserved ) sendMessageToClients ( 'message' , 'ok - reserved budget' ) ; else sendMessageToClients ( 'message' , 'failed - not able to reserve budget' ) ; } , function ( ) { sendMessageToClients ( 'message' , 'failed - error while trying to reserve budget' ) ; } ) ; }
Request a reservation for a silent push.
Request a reservation for a silent push .