Skip to content

Commit

Permalink
fix: handler (#885)
Browse files Browse the repository at this point in the history
  • Loading branch information
czy88840616 authored Mar 6, 2021
1 parent b0b3733 commit 89c6b53
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
8 changes: 5 additions & 3 deletions packages/core/src/functional/configuration.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,14 @@ import { IMidwayApplication, IMidwayContainer } from '../interface';
import { InjectionConfigurationOptions } from '@midwayjs/decorator';

export class FunctionalConfiguration {
private readHandler;
private readyHandler;
private stopHandler;
private options: InjectionConfigurationOptions;

constructor(options: InjectionConfigurationOptions) {
this.options = options;
this.readyHandler = () => {};
this.stopHandler = () => {};
}

onReady(
Expand All @@ -17,9 +19,9 @@ export class FunctionalConfiguration {
app?: IMidwayApplication
) {
if (typeof readyHandler === 'function') {
this.readHandler = readyHandler;
this.readyHandler = readyHandler;
} else {
this.readHandler(readyHandler, app);
this.readyHandler(readyHandler, app);
}
return this;
}
Expand Down
1 change: 0 additions & 1 deletion packages/faas/src/interface.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ export interface FunctionHandler {
handler(...args);
}


export type Application = IMidwayFaaSApplication;

export interface Context extends FaaSContext {};
Expand Down

0 comments on commit 89c6b53

Please sign in to comment.
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy