account for non-uuid messages in replay redemption
All checks were successful
Build & Publish / build (push) Successful in 3m33s
All checks were successful
Build & Publish / build (push) Successful in 3m33s
This commit is contained in:
parent
c49a29d461
commit
18852917cb
@ -39,7 +39,7 @@ class Twitch : KordExKoinComponent {
|
|||||||
// Send a message to the channel
|
// Send a message to the channel
|
||||||
val channel = botRef!!.kordRef.getGuildOrNull(Snowflake(1130932838200512584))!!
|
val channel = botRef!!.kordRef.getGuildOrNull(Snowflake(1130932838200512584))!!
|
||||||
.getChannelOf<GuildMessageChannel>(Snowflake(1130954956892029060))
|
.getChannelOf<GuildMessageChannel>(Snowflake(1130954956892029060))
|
||||||
val replay = ReplayCollection().get(event.message)
|
val replay = ReplayCollection().get(event.message) ?: return@launch
|
||||||
channel.createMessage {
|
channel.createMessage {
|
||||||
content = "Replay redeemed by: ${event.user.name}"
|
content = "Replay redeemed by: ${event.user.name}"
|
||||||
this.addFile("replay.osr", ChannelProvider(null) { ByteReadChannel(replay!!.replayFile) })
|
this.addFile("replay.osr", ChannelProvider(null) { ByteReadChannel(replay!!.replayFile) })
|
||||||
|
Loading…
x
Reference in New Issue
Block a user