Skip to content

Commit

Permalink
Merge pull request #161 from midwayjs/small_refactor
Browse files Browse the repository at this point in the history
chore: change error method name and clean code
  • Loading branch information
czy88840616 committed Mar 7, 2019
2 parents 0dc42d3 + 2301ec7 commit 466ed66
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 16 deletions.
4 changes: 2 additions & 2 deletions packages/midway-core/src/loader.ts
Expand Up @@ -39,14 +39,14 @@ export class ContainerLoader {

registerAllHook(hookKey, hookHandler) {
this.registerApplicationHook(hookKey, hookHandler);
this.registerRequeastHook(hookKey, hookHandler);
this.registerRequestHook(hookKey, hookHandler);
}

registerApplicationHook(hookKey, hookHandler) {
this.applicationContext.registerDataHandler(hookKey, hookHandler);
}

registerRequeastHook(hookKey, hookHandler) {
registerRequestHook(hookKey, hookHandler) {
this.requestContext.registerDataHandler(hookKey, hookHandler);
}

Expand Down
1 change: 1 addition & 0 deletions packages/midway-decorator/src/index.ts
Expand Up @@ -3,6 +3,7 @@ export * from './constant';
export * from './common/schedule';
export * from './common/priority';
export * from './faas/fun';
export * from './faas/handler';
export * from './web/requestMapping';
export * from './web/controller';
export * from './framework/config';
Expand Down
10 changes: 0 additions & 10 deletions packages/midway-web/src/constants.ts

This file was deleted.

4 changes: 0 additions & 4 deletions packages/midway-web/src/utils.ts
Expand Up @@ -45,7 +45,3 @@ export function getMethodNames(obj) {
export function isTypeScriptEnvironment() {
return !!require.extensions['.ts'];
}

export function isPluginName(name) {
return typeof name === 'string' && !/^_/.test(name);
}

0 comments on commit 466ed66

Please sign in to comment.