Skip to content

Commit

Permalink
docs: update comment
Browse files Browse the repository at this point in the history
  • Loading branch information
wanghx committed Jul 1, 2022
1 parent 49a8e02 commit ea43087
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/core-decorator/src/decorator/Inject.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ export interface InjectParams {

export function Inject(param?: InjectParams | string) {
return function(target: any, propertyKey: PropertyKey) {
// params allow string, or object
let objName: PropertyKey | undefined;
if (!param) {
// try to read design:type from proto
Expand All @@ -20,6 +19,7 @@ export function Inject(param?: InjectParams | string) {
objName = info?.name;
}
} else {
// params allow string, or object
objName = typeof param === 'string' ? param : param?.name;
}

Expand Down

0 comments on commit ea43087

Please sign in to comment.