refactor: use C++20's contains() method (#45742)

* chore: use std::map<>::contains() instead of count() or find()

* chore: use std::map<>::contains() instead of base::Contains()
This commit is contained in:
Charles Kerr 2025-02-21 17:33:43 -06:00 committed by GitHub
parent 612da3ec47
commit 2a383e9ddd
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
29 changed files with 54 additions and 77 deletions

View file

@ -83,7 +83,7 @@ AutofillDriver* AutofillDriverFactory::DriverForFrame(
driver.get());
} else {
driver_map_.erase(insertion_result.first);
DCHECK_EQ(driver_map_.count(render_frame_host), 0u);
DCHECK(!driver_map_.contains(render_frame_host));
return nullptr;
}
}