Skip to content

Commit

Permalink
fix(request-store-api): fix some fuction params default values
Browse files Browse the repository at this point in the history
  • Loading branch information
leomp12 committed Jul 10, 2019
1 parent 2b65645 commit 2fc15b8
Showing 1 changed file with 14 additions and 5 deletions.
19 changes: 14 additions & 5 deletions src/methods/request-store-api.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ const requestStoreApi = (
method = 'get',
data,
storeId = _config.get('store_id'),
authenticationId = _config.get('authentication_id'),
accessToken = _config.get('access_token'),
authenticationId,
accessToken,
axiosConfig
) => {
let timeout, baseURL
Expand Down Expand Up @@ -81,10 +81,19 @@ const requestStoreApi = (
* @param {string} [method='get'] - Request method (HTTP verb)
* @param {object} [data] - Request body object
* @param {number} [storeId=_config.get('store_id')] - E-Com Plus Store ID number
* @param {string} [authenticationId=_config.get('authentication_id')] - My ID for authenticated request
* @param {string} [accessToken=_config.get('access_token')] - Access token for authenticated request
* @param {string} [authenticationId] - My ID for authenticated request
* @param {string} [accessToken] - Access token for authenticated request
* @param {object} [axiosConfig] - Additional settings with custom axios config object
* @returns {promise}
* @returns {Promise<response|error>}
* Axios request promise resolved with
* [response]{@link https://github.com/axios/axios#response-schema}
* or rejected with
* [error]{@link https://github.com/axios/axios#handling-errors}.
*
* @example
* ecomClient.requestStoreApi('/products.json')
* .then(response => console.log(response.data))
* .catch(error => console.error(error))
*/

export default requestStoreApi

0 comments on commit 2fc15b8

Please sign in to comment.