function loadOptions(skipUsers) {
  const defaultResponse = {
    options: [],
    complete: true,
  };

  return APIRequest('/searchUsers', { complete: 1 }, defaultResponse)
    .then(({ complete, options }) => ({
      complete,
      options: options.filter(({ value }) => (skipUsers.indexOf(value) === -1)),
    }));
}
/**
 * Fetch list of users for searching
 *
 * @param {Array} skipUsers users to filter from results
 * @return {Promise}
 */
Fetch list of users for searching
@param {Array} skipUsers users to filter from results
@return {Promise}
Fetch list of users for searching @param { Array } skipUsers users to filter from results @return { Promise }
function loadOptions(skipUsers) {
  const defaultResponse = {
    options: [],
    complete: true,
  };
  return APIRequest('/searchUsers', { complete: 1 }, defaultResponse)
    .then(({ complete, options }) => ({
      complete,
      options: options.filter(({ value }) => (skipUsers.indexOf(value) === -1)),
    }));
}
function loadOptions ( skipUsers ) { const defaultResponse = { options : [ ] , complete : true , } ; return APIRequest ( '/searchUsers' , { complete : 1 } , defaultResponse ) . then ( ( { complete , options } ) => ( { complete , options : options . filter ( ( { value } ) => ( skipUsers . indexOf ( value ) === - 1 ) ) , } ) ) ; }
Fetch list of users for searching
 @param {Array} skipUsers users to filter from results
 @return {Promise}
Fetch list of users for searching @param { Array } skipUsers users to filter from results @return { Promise }