@algolia/client-account
Advanced tools
Comparing version 4.0.0-beta.15 to 4.0.0-beta.16
@@ -5,2 +5,3 @@ 'use strict'; | ||
var clientCommon = require('@algolia/client-common'); | ||
var clientSearch = require('@algolia/client-search'); | ||
@@ -23,15 +24,2 @@ | ||
function createWaitablePromise(promise, wait = (_response, _requestOptions) => { | ||
return Promise.resolve(); | ||
}) { | ||
// eslint-disable-next-line functional/immutable-data | ||
return Object.assign(promise, { | ||
wait(requestOptions) { | ||
return createWaitablePromise(promise | ||
.then(response => Promise.all([wait(response, requestOptions), response])) | ||
.then(promiseResults => promiseResults[1])); | ||
}, | ||
}); | ||
} | ||
const accountCopyIndex = (source, destination, requestOptions) => { | ||
@@ -66,3 +54,3 @@ // eslint-disable-next-line functional/prefer-readonly-type | ||
.then(() => Promise.resolve()); | ||
return createWaitablePromise(promise, () => Promise.all(responses.map(response => response.wait()))); | ||
return clientCommon.createWaitablePromise(promise, () => Promise.all(responses.map(response => response.wait()))); | ||
}; | ||
@@ -69,0 +57,0 @@ |
@@ -0,1 +1,2 @@ | ||
import { createWaitablePromise } from '@algolia/client-common'; | ||
import { exists, getSettings, setSettings, browseRules, saveRules, browseSynonyms, saveSynonyms, browseObjects, saveObjects } from '@algolia/client-search'; | ||
@@ -18,15 +19,2 @@ | ||
function createWaitablePromise(promise, wait = (_response, _requestOptions) => { | ||
return Promise.resolve(); | ||
}) { | ||
// eslint-disable-next-line functional/immutable-data | ||
return Object.assign(promise, { | ||
wait(requestOptions) { | ||
return createWaitablePromise(promise | ||
.then(response => Promise.all([wait(response, requestOptions), response])) | ||
.then(promiseResults => promiseResults[1])); | ||
}, | ||
}); | ||
} | ||
const accountCopyIndex = (source, destination, requestOptions) => { | ||
@@ -33,0 +21,0 @@ // eslint-disable-next-line functional/prefer-readonly-type |
{ | ||
"name": "@algolia/client-account", | ||
"version": "4.0.0-beta.15", | ||
"version": "4.0.0-beta.16", | ||
"private": false, | ||
"license": "MIT", | ||
"sideEffects": false, | ||
"main": "index.js", | ||
"module": "dist/client-account.esm.js", | ||
"types": "dist/client-account.d.ts", | ||
"files": [ | ||
@@ -10,9 +14,7 @@ "index.js", | ||
], | ||
"sideEffects": false, | ||
"main": "index.js", | ||
"module": "dist/client-account.esm.js", | ||
"types": "dist/client-account.d.ts", | ||
"dependencies": { | ||
"@algolia/client-search": "4.0.0-beta.15" | ||
"@algolia/client-common": "4.0.0-beta.16", | ||
"@algolia/client-search": "4.0.0-beta.16", | ||
"@algolia/transporter": "4.0.0-beta.16" | ||
} | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
5727
3
113
+ Added@algolia/cache-common@4.0.0-beta.16(transitive)
+ Added@algolia/client-common@4.0.0-beta.16(transitive)
+ Added@algolia/client-search@4.0.0-beta.16(transitive)
+ Added@algolia/logger-common@4.0.0-beta.16(transitive)
+ Added@algolia/requester-common@4.0.0-beta.16(transitive)
+ Added@algolia/transporter@4.0.0-beta.16(transitive)
- Removed@algolia/cache-common@4.0.0-beta.15(transitive)
- Removed@algolia/client-common@4.0.0-beta.15(transitive)
- Removed@algolia/client-search@4.0.0-beta.15(transitive)
- Removed@algolia/logger-common@4.0.0-beta.15(transitive)
- Removed@algolia/requester-common@4.0.0-beta.15(transitive)
- Removed@algolia/transporter@4.0.0-beta.15(transitive)