mirror of
https://github.com/wassname/talk.git
synced 2026-10-01 12:42:56 +08:00
Update plugins.js
This commit is contained in:
1 parent
9158faf295
commit
d1951c8504
1 file changed
+4
@@ -135,6 +135,10 @@ class PluginsService {
|
||||
.filter(o => o.module.slots && o.module.slots[slot])
|
||||
.map(o => o.module.slots[slot])
|
||||
);
|
||||
|
||||
if (slotSize > 0 && slots.length > slotSize) {
|
||||
console.warn(`Slot[${slot}] supports a maximum of ${slotSize} plugins providing slots, got ${slots.length}, will only use the first ${slotSize}`);
|
||||
}
|
||||
|
||||
return (slotSize > 0 ? slots.slice(0, slotSize) : slots)
|
||||
.map((component, i) => ({
|
||||
|
||||
Reference in new issue
Block a user