koishi-plugin-echo-cave 1.16.14 → 1.16.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/index.cjs +6 -1
- package/package.json +1 -1
package/lib/index.cjs
CHANGED
|
@@ -183,7 +183,7 @@ function parseUserIds(userIds) {
|
|
|
183
183
|
}
|
|
184
184
|
} catch (e) {
|
|
185
185
|
const num = Number(userId);
|
|
186
|
-
if (Number.isNaN(num)) {
|
|
186
|
+
if (!Number.isNaN(num)) {
|
|
187
187
|
parsedUserIds.push(userId);
|
|
188
188
|
}
|
|
189
189
|
}
|
|
@@ -591,6 +591,11 @@ function apply(ctx, cfg) {
|
|
|
591
591
|
);
|
|
592
592
|
ctx.command("cave.bind <id:number> <...userIds>", { authority: 4 }).action(
|
|
593
593
|
async ({ session }, id, ...userIds) => {
|
|
594
|
+
ctx.logger.info(`Binding users ${JSON.stringify(userIds)} to cave ID ${id}`);
|
|
595
|
+
for (const uid of userIds) {
|
|
596
|
+
ctx.logger.info(`User ID to bind: ${uid}`);
|
|
597
|
+
ctx.logger.info(`userid type: ${typeof uid}`);
|
|
598
|
+
}
|
|
594
599
|
await bindUsersToCave(ctx, session, id, userIds);
|
|
595
600
|
}
|
|
596
601
|
);
|