@wix/api-client
Advanced tools
Comparing version 1.12.2 to 1.12.3
import { WixClient } from './wixClient.js'; | ||
export declare function elevate<T extends (...arg: any) => any>(func: T): T; | ||
import { RESTFunctionDescriptor } from '@wix/sdk-types'; | ||
export declare function elevate<T extends RESTFunctionDescriptor>(restModule: T): T; | ||
export declare const fetchWithAuth: WixClient['fetchWithAuth']; | ||
export declare const graphql: WixClient['graphql']; | ||
export { setGlobalWixContext } from './wix-context.js'; |
import { resolveContext } from '@wix/sdk-runtime/context'; | ||
export function elevate(func) { | ||
return ((...args) => { | ||
let fullArgs = Array(func.length) | ||
.fill(undefined) | ||
.map((_, index) => args[index]); | ||
// support old EDMs | ||
if (fullArgs.length === 0) { | ||
fullArgs = args; | ||
} | ||
return func(...fullArgs, { suppressAuth: true }); | ||
}); | ||
import { createRESTModule } from '@wix/sdk-runtime/rest-modules'; | ||
export function elevate(restModule) { | ||
return createRESTModule(restModule, true); | ||
} | ||
@@ -14,0 +6,0 @@ export const fetchWithAuth = async (...args) => { |
{ | ||
"name": "@wix/api-client", | ||
"version": "1.12.2", | ||
"version": "1.12.3", | ||
"license": "UNLICENSED", | ||
@@ -28,3 +28,3 @@ "main": "build/index.js", | ||
"@wix/sdk-context": "^0.0.1", | ||
"@wix/sdk-runtime": "0.3.4", | ||
"@wix/sdk-runtime": "0.3.5", | ||
"@wix/sdk-types": "^1.9.1", | ||
@@ -39,3 +39,3 @@ "crypto-js": "^4.2.0", | ||
"@wix/metro-runtime": "^1.1677.0", | ||
"@wix/sdk": "1.12.2" | ||
"@wix/sdk": "1.12.3" | ||
}, | ||
@@ -53,3 +53,3 @@ "wix": { | ||
}, | ||
"falconPackageHash": "791bb9900d0cd3694e8173a413976578fafa2d2d98247998e3c70276" | ||
"falconPackageHash": "96eb5a3bbeb6c3ec142c0f23068ee3c84862003bf61d5d2579927ff1" | ||
} |
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
82335
2005
+ Added@wix/sdk-runtime@0.3.5(transitive)
- Removed@wix/sdk-runtime@0.3.4(transitive)
Updated@wix/sdk-runtime@0.3.5