Always call back when printer changes
Otherwise it can happen that we swallow previous printer updates and never end up getting a valid on-printers-updated call. Fixes: 156222510 Test: atest PrinterDiscoverySessionLifecycleTest Change-Id: Idab7399a6ab41ba9051cfcbbeebf4c45d6bfc053
This commit is contained in:
@@ -231,11 +231,6 @@ public final class FusedPrintersProvider extends Loader<List<PrinterInfo>>
|
||||
// Add the new printers, i.e. what is left.
|
||||
printers.addAll(discoveredPrinters.values());
|
||||
|
||||
// Do nothing if the printer list is not changed.
|
||||
if (Objects.equals(mPrinters, printers)) {
|
||||
return;
|
||||
}
|
||||
|
||||
// Update the list of printers.
|
||||
mPrinters.clear();
|
||||
mPrinters.addAll(printers);
|
||||
|
||||
Reference in New Issue
Block a user