Repository navigation
Fix member leave event listener not being able to find a thread - #740
Conversation
|
what is the actual diff? since you renamed, github doesnt show a proper diff... so its hard to review. |
previously it used db to store authors and thread id, which is good we have all the threads in storage, but on jda side it used cache to search for the threads, which is not ideal coz not all threads are always cached, hence the errors. now i use retrieveActiveThreads method to get the threads which is not cache based and then i filter it and close the ones made by leaver. |
Zabuzard
left a comment
There was a problem hiding this comment.
works, but is there a way to retrieve active threads from a channel? i would prefer an approach like helpForumChannel.retrieveActiveThreads()... to avoid retrieving all and then matching the pattern afterwards.
actually there is a method but it is a get method not a retrieve method https://javadoc.io/doc/net.dv8tion/JDA/latest/net/dv8tion/jda/api/entities/channel/attribute/IThreadContainer.html#getThreadChannels() |
|
Kudos, SonarCloud Quality Gate passed! |
|
Probably via cache again, since it doesnt return a RestAction, ...? |
yea most probably its cache, tho the description doesn't talk about that |








closes #619