Skip to content

Commit e42767d

Browse files
committed
fix typing
1 parent f34fdac commit e42767d

File tree

2 files changed

+3
-8
lines changed

2 files changed

+3
-8
lines changed

Tasks/GhostThemeUploader/ghostv2.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import * as tl from "azure-pipelines-task-lib/task";
22

3-
const GhostAdminApiClient = require("@tryghost/admin-api");
3+
import GhostAdminApiClient = require("@tryghost/admin-api");
44

55
export interface Options {
66
blogUrl: string;
@@ -20,5 +20,5 @@ export async function themeUploadV2(options: Options) {
2020
version: options.version
2121
});
2222

23-
await client.api.themes.upload({ file: options.themePath });
23+
await client.themes.upload({ file: options.themePath });
2424
}

typings/tryghostAdminApi.d.ts

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,14 +13,9 @@ declare module "@tryghost/admin-api" {
1313
upload(data: ThemeData): PromiseLike<any>;
1414
}
1515

16-
class AdminApi {
17-
themes: ThemesApi;
18-
}
19-
2016
class GhostAdminApiClient {
2117
constructor(options: AdminApiOptions);
22-
23-
public api: AdminApi;
18+
themes: ThemesApi;
2419
}
2520

2621
export = GhostAdminApiClient;

0 commit comments

Comments
 (0)