Skip to content

Commit

Permalink
Check for null transmitter receiver
Browse files Browse the repository at this point in the history
  • Loading branch information
stashymane committed Feb 13, 2024
1 parent 5955d6e commit 7bb1a4f
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ class MidiDeviceJvm(private val device: javax.sound.midi.MidiDevice, index: Int)
}

override fun close() {
device.transmitter.receiver.close()
device.transmitter?.receiver?.close()
channel.close()
}
}
Expand Down

0 comments on commit 7bb1a4f

Please sign in to comment.