Skip to content

Commit

Permalink
refactor: clean code
Browse files Browse the repository at this point in the history
  • Loading branch information
jbpionnier committed Sep 20, 2018
1 parent 558e33f commit d37ec23
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions packages/core/injector/module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -241,7 +241,7 @@ export class Module {
}

public addCustomClass(component: CustomClass, collection: Map<string, any>) {
const { provide, name, useClass } = component;
const { name, useClass } = component;
collection.set(name, {
name,
metatype: useClass,
Expand All @@ -251,7 +251,7 @@ export class Module {
}

public addCustomValue(component: CustomValue, collection: Map<string, any>) {
const { provide, name, useValue: value } = component;
const { name, useValue: value } = component;
collection.set(name, {
name,
metatype: null,
Expand All @@ -266,7 +266,7 @@ export class Module {
component: CustomFactory,
collection: Map<string, any>,
) {
const { provide, name, useFactory: factory, inject } = component;
const { name, useFactory: factory, inject } = component;
collection.set(name, {
name,
metatype: factory as any,
Expand Down

0 comments on commit d37ec23

Please sign in to comment.