Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 9b1db24f authored by Treehugger Robot's avatar Treehugger Robot Committed by Gerrit Code Review
Browse files

Merge "Fix UsbDeviceManager null object reference"

parents 2d82493d ab87b44d
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -539,7 +539,8 @@ public class UsbDeviceManager implements ActivityManagerInternal.ScreenObserver
            // We do not show the USB notification if the primary volume supports mass storage.
            // The legacy mass storage UI will be used instead.
            final StorageManager storageManager = StorageManager.from(mContext);
            final StorageVolume primary = storageManager.getPrimaryVolume();
            final StorageVolume primary =
                    storageManager != null ? storageManager.getPrimaryVolume() : null;

            boolean massStorageSupported = primary != null && primary.allowMassStorage();
            mUseUsbNotification = !massStorageSupported && mContext.getResources().getBoolean(