Use an Optional wrapper in TileLifecycleManager
This way, we can prevent NPE, as the variable is never null. Aditionally, make sure that we always perform operations directly on Optional. It's hard to test the NPE because of thread issues, but with this fix we can guarantee: * No NPE thanks to Optional * Behavior is maintained thanks to CTS Test: atest TileLifecycleManagerTest Test: atest CtsTileServiceTestCases Test: atest CtsSystemUiHostTestCases Fixes: 317014639 Flag: NONE Change-Id: I27a5e5b4ced1fe5da9b0e4b686cb5e58ca820c8c
Loading
Please register or sign in to comment