@cloudbase/auth 2.24.5 → 2.24.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cloudbase/auth",
3
- "version": "2.24.5",
3
+ "version": "2.24.7",
4
4
  "description": "cloudbase javascript sdk auth componets",
5
5
  "main": "dist/cjs/index.js",
6
6
  "module": "dist/esm/index.js",
@@ -32,14 +32,14 @@
32
32
  "license": "Apache-2.0",
33
33
  "dependencies": {
34
34
  "@cloudbase/adapter-wx_mp": "^1.2.1",
35
- "@cloudbase/oauth": "2.24.5",
36
- "@cloudbase/utilities": "2.24.5"
35
+ "@cloudbase/oauth": "2.24.7",
36
+ "@cloudbase/utilities": "2.24.7"
37
37
  },
38
38
  "devDependencies": {
39
- "@cloudbase/types": "2.24.5",
39
+ "@cloudbase/types": "2.24.7",
40
40
  "@types/node": "^22.1.0",
41
41
  "terser-webpack-plugin": "^3.0.2",
42
42
  "webpack-bundle-analyzer": "^4.9.1"
43
43
  },
44
- "gitHead": "4eb6054371f9880c4b2c6ae59446a0a9ae118d55"
44
+ "gitHead": "d3df65b07405f0e29866486dc0e804fa30070414"
45
45
  }
package/src/adapter.ts CHANGED
@@ -202,8 +202,8 @@ const dealUserAdapter = (config: AuthOptions, adapter: SDKAdapterInterface) => {
202
202
  res = await func({ url, ...options })
203
203
  res = dealAdapterRequestData(res, { ...options, url })
204
204
  } catch (error) {
205
- res = error
206
- throw error
205
+ res = { ...error?.data, ...error }
206
+ throw res
207
207
  }
208
208
 
209
209
  if (res?.error) {
package/src/index.ts CHANGED
@@ -54,6 +54,7 @@ export type {
54
54
  ResendReq,
55
55
  SetSessionReq,
56
56
  DeleteMeReq,
57
+ SignUpRes,
57
58
  } from './type'
58
59
 
59
60
  declare const cloudbase: ICloudbase
package/src/type.ts CHANGED
@@ -220,7 +220,7 @@ export interface VerifyOtpReq {
220
220
  email?: string // 邮箱(可选,与手机号二选一)
221
221
  phone?: string // 手机号(可选,与邮箱二选一)
222
222
  token: string // 验证码(必填)
223
- messageId: string // 验证码对应ID(必填)
223
+ messageId?: string // 验证码对应ID(可选)
224
224
  }
225
225
 
226
226
  export interface SignInWithOtpReq {