We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 736972a commit d09e9beCopy full SHA for d09e9be
src/behavioral/Plugin.ts
@@ -75,7 +75,7 @@ export class PluginManager<T> {
75
this.plugins = []
76
}
77
78
- register(...plugins: Plugin<T>[] | string[]): boolean {
+ register(...plugins: Plugin<T>[]): boolean {
79
for (const plugin of plugins) {
80
const i = this.indexOf(plugin)
81
@@ -122,8 +122,8 @@ export class PluginManager<T> {
122
protected indexOf(plugin: Plugin<T> | string): number {
123
const plugins = this.plugins
124
const name = 'string' === typeof plugin
125
- ? plugin
126
- : plugin.name
+ ? plugin
+ : plugin.name
127
128
for (let i = plugins.length - 1; i >= 0; --i) {
129
if (name === plugins[i].name) {
0 commit comments