src/googledrive.js
function (id) {
    return this._request('GET', BASE_URL + '/drive/v2/files/' + id, {}).then(function (response) {
      if (response.status === 200) {
        return Promise.resolve(JSON.parse(response.responseText));
      } else {
        return Promise.reject("request (getting metadata for " + id + ") failed with status: " + response.status);
      }
    });
  }
function (id) {
    return this._request('GET', BASE_URL + '/drive/v2/files/' + id, {}).then(function (response) {
      if (response.status === 200) {
        return Promise.resolve(JSON.parse(response.responseText));
      } else {
        return Promise.reject("request (getting metadata for " + id + ") failed with status: " + response.status);
      }
    });
  }
function ( id ) { return this . _request ( 'GET' , BASE_URL + '/drive/v2/files/' + id , { } ) . then ( function ( response ) { if ( response . status === 200 ) { return Promise . resolve ( JSON . parse ( response . responseText ) ) ; } else { return Promise . reject ( "request (getting metadata for " + id + ") failed with status: " + response . status ) ; } } ) ; }
Get the metadata for a given file ID.

@param {string} id - File ID
@returns {Promise} Resolves with an object containing the metadata

@private
Get the metadata for a given file ID .