mirror of
https://github.com/rhunk/SnapEnhance.git
synced 2025-05-29 21:10:20 +02:00
fix(unlimitedsnapviewtime): has audio npe
This commit is contained in:
parent
edba592241
commit
2207b1a61d
@ -22,10 +22,11 @@ class UnlimitedSnapViewTime :
|
||||
if (message.messageContent.contentType != ContentType.SNAP) return@hookConstructor
|
||||
|
||||
with(message.messageContent) {
|
||||
val hasSound = ProtoReader(this.content).getInt(11, 5, 2, 5)!!
|
||||
this.content = ProtoEditor(this.content).apply {
|
||||
edit(11, 5, 2) {
|
||||
writeConstant(5, hasSound)
|
||||
ProtoReader(this@with.content).getInt(11, 5, 2, 5)?.let {
|
||||
writeConstant(5, it)
|
||||
}
|
||||
writeBuffer(6, byteArrayOf())
|
||||
}
|
||||
}.toByteArray()
|
||||
|
Loading…
x
Reference in New Issue
Block a user