chore: prefer empty() check for readability (#29360)
This commit is contained in:
parent
77ecc7d432
commit
9bb7051f54
4 changed files with 5 additions and 6 deletions
|
@ -177,7 +177,7 @@ std::vector<blink::MessagePortChannel> MessagePort::DisentanglePorts(
|
|||
v8::Isolate* isolate,
|
||||
const std::vector<gin::Handle<MessagePort>>& ports,
|
||||
bool* threw_exception) {
|
||||
if (!ports.size())
|
||||
if (ports.empty())
|
||||
return std::vector<blink::MessagePortChannel>();
|
||||
|
||||
std::unordered_set<MessagePort*> visited;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue