function promiseIsURIVisited(url) {
  let deferred = Promise.defer();
  PlacesUtils.asyncHistory.isURIVisited(Utils.makeURI(url), function(aURI, aIsVisited) {
    deferred.resolve(aIsVisited);
  });

  return deferred.promise;
}
/**
 * Asynchronously check a url is visited.
 * @param url the url
 * @return {Promise}
 * @resolves When the check has been added successfully.
 * @rejects JavaScript exception.
 */
Asynchronously check a url is visited.
@param url the url
@return {Promise}
@resolves When the check has been added successfully.
Asynchronously check a url is visited . @param url the url @return { Promise } @resolves When the check has been added successfully .
function promiseIsURIVisited(url) {
  let deferred = Promise.defer();
  PlacesUtils.asyncHistory.isURIVisited(Utils.makeURI(url), function(aURI, aIsVisited) {
    deferred.resolve(aIsVisited);
  });
  return deferred.promise;
}
function promiseIsURIVisited ( url ) { let deferred = Promise . defer ( ) ; PlacesUtils . asyncHistory . isURIVisited ( Utils . makeURI ( url ) , function ( aURI , aIsVisited ) { deferred . resolve ( aIsVisited ) ; } ) ; return deferred . promise ; }
Asynchronously check a url is visited.
Asynchronously check a url is visited .