index.js
function find(domain, query) {
    if (query.name && !query.name.includes(domain)) {
      query.name = query.name + '.' + domain;
    }
    if (query.query) {
      query = _.extend(query, query.query);
      delete query.query;
    }
    return getZone(domain).then(function (zone) {
      return self.cloudflareClient.findRecord(zone.id, query);
    });
  }
function find(domain, query) {
    if (query.name && !query.name.includes(domain)) {
      query.name = query.name + '.' + domain;
    }
    if (query.query) {
      query = _.extend(query, query.query);
      delete query.query;
    }
    return getZone(domain).then(function (zone) {
      return self.cloudflareClient.findRecord(zone.id, query);
    });
  }
function find ( domain , query ) { if ( query . name && ! query . name . includes ( domain ) ) { query . name = query . name + '.' + domain ; } if ( query . query ) { query = _ . extend ( query , query . query ) ; delete query . query ; } return getZone ( domain ) . then ( function ( zone ) { return self . cloudflareClient . findRecord ( zone . id , query ) ; } ) ; }
Find a given record
@param domain
@param query
@return {Promise}
Find a given record