B2G/gecko/toolkit/components/downloads/test/unit/test_privatebrowsing.js
/**
 * Try to see if a download is available using the |getDownload| method.  The
 * download can both be active or inactive.
 */
Try to see if a download is available using the |getDownload| method.  The
download can both be active or inactive.
Try to see if a download is available using the |getDownload| method . The download can both be active or inactive .
function is_download_available(aID, aSrc, aDst, aName) {
  let download;
  try {
    download = dm.getDownload(aID);
  } catch (ex) {
    return false;
  }
  return (download.id == aID &&
          download.source.spec == aSrc &&
          download.targetFile.path == aDst.path &&
          download.displayName == aName);
}
function is_download_available ( aID , aSrc , aDst , aName ) { let download ; try { download = dm . getDownload ( aID ) ; } catch ( ex ) { return false ; } return ( download . id == aID && download . source . spec == aSrc && download . targetFile . path == aDst . path && download . displayName == aName ) ; }
Try to see if a download is available using the |getDownload| method.
Try to see if a download is available using the |getDownload| method .