Skip to content

Commit 409dd1e

Browse files
committed
Improve channel validation
1 parent c3eb3e4 commit 409dd1e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cron/thread-lifecycle.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ module.exports = {
5353
const archiveThreshold = weekdaysBefore(moment(), 4)
5454

5555
channels
56-
.filter((channel) => channel.isText() && channel.viewable)
56+
.filter((channel) => channel && channel.isText() && channel.viewable)
5757
.forEach(async (channel) => {
5858
const threads = await channel.threads.fetch()
5959
threads.threads.forEach(async (thread) => {

0 commit comments

Comments
 (0)