B2G/gecko/browser/modules/NewTabUtils.jsm
/**
   * Gets the value for a given key from the storage.
   * @param aKey The storage key (a string).
   * @param aDefault A default value if the key doesn't exist.
   * @return The value for the given key.
   */
Gets the value for a given key from the storage.
@param aKey The storage key (a string).
@param aDefault A default value if the key doesn't exist.
@return The value for the given key.
Gets the value for a given key from the storage . @param aKey The storage key ( a string ) . @param aDefault A default value if the key doesn ' t exist . @return The value for the given key .
function Storage_get(aKey, aDefault) {
    let value;
    try {
      let prefValue = Services.prefs.getComplexValue(this._prefs[aKey],
                                                     Ci.nsISupportsString).data;
      value = JSON.parse(prefValue);
    } catch (e) {}
    return value || aDefault;
  }
function Storage_get ( aKey , aDefault ) { let value ; try { let prefValue = Services . prefs . getComplexValue ( this . _prefs [ aKey ] , Ci . nsISupportsString ) . data ; value = JSON . parse ( prefValue ) ; } catch ( e ) { } return value || aDefault ; }
Gets the value for a given key from the storage.
Gets the value for a given key from the storage .