Skip to content

Commit

Permalink
fix(cli): appConfigurators setClient in type
Browse files Browse the repository at this point in the history
  • Loading branch information
eikeland committed Aug 16, 2024
1 parent 5173f3f commit e91a544
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions packages/modules/app/src/AppConfigurator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,9 @@ export interface AppModuleConfig {

export interface IAppConfigurator {
setClient: (
client_or_cb: AppModuleConfig['client'] | ConfigBuilderCallback<AppModuleConfig['client']>,
client_or_cb:
| Promise<AppModuleConfig['client']>
| ConfigBuilderCallback<AppModuleConfig['client']>,
) => void;
setBaseUri: (base_or_cb: string | ConfigBuilderCallback<string>) => void;
}
Expand Down Expand Up @@ -61,7 +63,9 @@ export class AppConfigurator
}

public setClient(
client_or_cb: AppModuleConfig['client'] | ConfigBuilderCallback<AppModuleConfig['client']>,
client_or_cb:
| Promise<AppModuleConfig['client']>
| ConfigBuilderCallback<AppModuleConfig['client']>,
) {
const cb = typeof client_or_cb === 'object' ? () => client_or_cb : client_or_cb;
this._set('client', cb);
Expand Down

0 comments on commit e91a544

Please sign in to comment.