Skip to content
This repository was archived by the owner on May 6, 2025. It is now read-only.

Commit 7d837fb

Browse files
committed
fix api export error
1 parent ec45f8a commit 7d837fb

3 files changed

Lines changed: 6 additions & 8 deletions

File tree

lib/index.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ const env_1 = require("./env");
1212
const function_1 = require("./function");
1313
const storage = __importStar(require("./storage"));
1414
const utils_1 = require("./utils");
15-
const code_update_1 = require("./commands/functions/code-update");
1615
module.exports = class CloudBase {
1716
constructor(secretId, secretKey) {
1817
this.login = auth_1.login;
@@ -38,7 +37,7 @@ module.exports = class CloudBase {
3837
detail: function_1.getFunctionDetail,
3938
log: function_1.getFunctionLog,
4039
code: {
41-
update: code_update_1.codeUpdate
40+
update: function_1.updateFunctionCode
4241
},
4342
config: {
4443
update: function_1.updateFunctionConfig

src/index.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,12 @@ import {
2121
deleteFunctionTrigger,
2222
invokeFunction,
2323
downloadFunctionCode,
24-
copyFunction
24+
copyFunction,
25+
updateFunctionCode
2526
} from './function'
2627
import * as storage from './storage'
2728
import { authStore } from './utils'
2829
import { ILoginOptions } from './types'
29-
import { codeUpdate } from './commands/functions/code-update'
3030

3131
export = class CloudBase {
3232
login: (
@@ -56,7 +56,7 @@ export = class CloudBase {
5656
detail: getFunctionDetail,
5757
log: getFunctionLog,
5858
code: {
59-
update: codeUpdate
59+
update: updateFunctionCode
6060
},
6161
config: {
6262
update: updateFunctionConfig

types/index.d.ts

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
11
import './commands';
22
import { listEnvs, createEnv, getEnvAuthDomains, createEnvDomain, deleteEnvDomain, getLoginConfigList, createLoginConfig, updateLoginConfig } from './env';
3-
import { createFunction, listFunction, deleteFunction, getFunctionDetail, getFunctionLog, updateFunctionConfig, createFunctionTriggers, deleteFunctionTrigger, invokeFunction, downloadFunctionCode, copyFunction } from './function';
3+
import { createFunction, listFunction, deleteFunction, getFunctionDetail, getFunctionLog, updateFunctionConfig, createFunctionTriggers, deleteFunctionTrigger, invokeFunction, downloadFunctionCode, copyFunction, updateFunctionCode } from './function';
44
import * as storage from './storage';
55
import { ILoginOptions } from './types';
6-
import { codeUpdate } from './commands/functions/code-update';
76
declare const _default: {
87
new (secretId: any, secretKey: any): {
98
login: (options: ILoginOptions) => Promise<{
@@ -32,7 +31,7 @@ declare const _default: {
3231
detail: typeof getFunctionDetail;
3332
log: typeof getFunctionLog;
3433
code: {
35-
update: typeof codeUpdate;
34+
update: typeof updateFunctionCode;
3635
};
3736
config: {
3837
update: typeof updateFunctionConfig;

0 commit comments

Comments
 (0)