refactor: return-braced-init-list pt 2 of 2 (#44870)

* refactor: more return-braced-init-list, this time for v8 and gin objects

* refactor: more return-braced-init-list, this time for v8, gin, std, and base objects
This commit is contained in:
Charles Kerr 2024-11-29 11:44:33 -06:00 committed by GitHub
parent 4a695d07c6
commit f7e823ac80
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
35 changed files with 64 additions and 64 deletions

View file

@ -107,11 +107,11 @@ class IPCRenderer final : public gin::Wrappable<IPCRenderer>,
v8::Local<v8::Value> arguments) {
if (!electron_ipc_remote_) {
thrower.ThrowError(kIPCMethodCalledAfterContextReleasedError);
return v8::Local<v8::Promise>();
return {};
}
blink::CloneableMessage message;
if (!electron::SerializeV8Value(isolate, arguments, &message)) {
return v8::Local<v8::Promise>();
return {};
}
gin_helper::Promise<blink::CloneableMessage> p(isolate);
auto handle = p.GetHandle();
@ -189,11 +189,11 @@ class IPCRenderer final : public gin::Wrappable<IPCRenderer>,
v8::Local<v8::Value> arguments) {
if (!electron_ipc_remote_) {
thrower.ThrowError(kIPCMethodCalledAfterContextReleasedError);
return v8::Local<v8::Value>();
return {};
}
blink::CloneableMessage message;
if (!electron::SerializeV8Value(isolate, arguments, &message)) {
return v8::Local<v8::Value>();
return {};
}
blink::CloneableMessage result;