Skip to content

Commit 58f2879

Browse files
fixing random artbot crashes
1 parent cbb7835 commit 58f2879

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/Classes/ArtIndexerBot.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -556,6 +556,9 @@ export class ArtIndexerBot {
556556
}
557557

558558
getRandomizedProjectBot(projectBots: ProjectBot[]): ProjectBot | undefined {
559+
if (!projectBots || projectBots.length === 0) {
560+
return undefined
561+
}
559562
let attempts = 0
560563
while (attempts < 10) {
561564
const projBot =

0 commit comments

Comments
 (0)