Skip to content

Commit

Permalink
chore: removed unneeded code
Browse files Browse the repository at this point in the history
  • Loading branch information
jkleinsc committed Nov 21, 2022
1 parent 95ca0a4 commit f4c37e5
Showing 1 changed file with 1 addition and 8 deletions.
9 changes: 1 addition & 8 deletions shell/browser/usb/usb_chooser_context.cc
Original file line number Diff line number Diff line change
Expand Up @@ -333,11 +333,8 @@ void UsbChooserContext::OnDeviceRemoved(
!device_info->serial_number.value().empty()) {
return;
}

std::vector<url::Origin> revoked_urls;
for (auto& map_entry : ephemeral_devices_) {
if (map_entry.second.erase(device_info->guid) > 0)
revoked_urls.push_back(map_entry.first);
map_entry.second.erase(device_info->guid);
}
}

Expand All @@ -347,10 +344,6 @@ void UsbChooserContext::OnDeviceManagerConnectionError() {
devices_.clear();
is_initialized_ = false;

// Store the revoked URLs to notify observers of the revoked permissions.
std::vector<url::Origin> revoked_origins;
for (auto& map_entry : ephemeral_devices_)
revoked_origins.push_back(map_entry.first);
ephemeral_devices_.clear();

// Notify all device observers.
Expand Down

0 comments on commit f4c37e5

Please sign in to comment.