function workerGetBudget() {
  navigator.budget.getBudget().then(function(budget) {
    sendMessageToClients('message',
        'ok - budget returned value of ' + budget[0].budgetAt);
  }, function() {
    sendMessageToClients('message', 'failed - unable to get budget values');
  });
}
// Query for the budget and return the current total.
Query for the budget and return the current total.
Query for the budget and return the current total .
function workerGetBudget() {
  navigator.budget.getBudget().then(function(budget) {
    sendMessageToClients('message',
        'ok - budget returned value of ' + budget[0].budgetAt);
  }, function() {
    sendMessageToClients('message', 'failed - unable to get budget values');
  });
}
function workerGetBudget ( ) { navigator . budget . getBudget ( ) . then ( function ( budget ) { sendMessageToClients ( 'message' , 'ok - budget returned value of ' + budget [ 0 ] . budgetAt ) ; } , function ( ) { sendMessageToClients ( 'message' , 'failed - unable to get budget values' ) ; } ) ; }
Query for the budget and return the current total.
Query for the budget and return the current total .