Closed WhiteKiwi closed 1 year ago
Only "@Foo(2)" is decorated in the following situations. Because SetMetadata overwrites the value for the key, more than one cannot be used.
const FOO = Symbol('FOO'); const Foo = (num: number) => SetMetedata(FOO, num) class SomeService { @Foo(1) @Foo(2) doSomething() { ... } }
No. Just Foo(1) works only. The metadata detector recognizes the Foo(1) only. Because It's the last one I decorated.
It will be resolved in v2.
Describe the bug
Only "@Foo(2)" is decorated in the following situations. Because SetMetadata overwrites the value for the key, more than one cannot be used.
Expected behavior
To Reproduce
Possible Solution
Additional context