refactor: use C++20's contains() method (35-x-y) (#45768)
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:
parent
2da02ec9bc
commit
4c81971213
29 changed files with 52 additions and 75 deletions
|
@ -6,7 +6,6 @@
|
|||
|
||||
#include <vector>
|
||||
|
||||
#include "base/containers/contains.h"
|
||||
#include "content/public/common/webplugininfo.h"
|
||||
#include "electron/buildflags/buildflags.h"
|
||||
#include "url/gurl.h"
|
||||
|
@ -53,8 +52,7 @@ PluginUtils::GetMimeTypeToExtensionIdMap(
|
|||
|
||||
if (MimeTypesHandler* handler = MimeTypesHandler::GetHandler(extension)) {
|
||||
for (const auto& supported_mime_type : handler->mime_type_set()) {
|
||||
DCHECK(!base::Contains(mime_type_to_extension_id_map,
|
||||
supported_mime_type));
|
||||
DCHECK(!mime_type_to_extension_id_map.contains(supported_mime_type));
|
||||
mime_type_to_extension_id_map[supported_mime_type] = extension_id;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue