do not needlessly run through Solid::Device::allDevices
ClosedPublic

Authored by sitter on Jan 20 2020, 12:09 PM.

Details

Summary

allDevice is bugging out and having duplicated entires
https://bugs.kde.org/show_bug.cgi?id=416495
this results in garbage in our tree view.
on top of that running through allDevices is entirely pointless
as we can directly construct a Device from the udi we got which
is not only faster, it also lets us bypass the aformentioned
bug since the udi is still unique it's only the objects that
get duped

BUG: 399746
FIXED-IN: 5.18.0

Test Plan

repated plug/unplug of usb drive doesn't cause bogus device entries

Diff Detail

Repository
R102 KInfoCenter
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
sitter created this revision.Jan 20 2020, 12:09 PM
Restricted Application added a project: Plasma. · View Herald TranscriptJan 20 2020, 12:09 PM
Restricted Application added a subscriber: plasma-devel. · View Herald Transcript
sitter requested review of this revision.Jan 20 2020, 12:09 PM
apol accepted this revision.Jan 20 2020, 12:23 PM
This revision is now accepted and ready to land.Jan 20 2020, 12:23 PM
ngraham accepted this revision.Jan 20 2020, 3:10 PM
This revision was automatically updated to reflect the committed changes.