MIDI: Add null check for UserManager.getMainUser

UserManager.getMainUser() can return null for some devices.
This is causing a NullPointerException in some automotive cases.

This CL adds an additional check to make sure that this is not null.

Bug: 322622902
Test: Connect to jamstick on phone with MIDI+BTLE app.
Test: Verify that MidiScope receives packets successfully.
Change-Id: I5b8e060cd8cafde1b1c60e259cc5ba0516a417d0
1 file changed