chore: return early on promise rejection (#29279)
This commit is contained in:
parent
8e1176cbc0
commit
79ae8b427c
1 changed files with 1 additions and 0 deletions
|
@ -290,6 +290,7 @@ v8::Local<v8::Promise> Cookies::Set(v8::Isolate* isolate,
|
||||||
const std::string* url_string = details.FindStringKey("url");
|
const std::string* url_string = details.FindStringKey("url");
|
||||||
if (!url_string) {
|
if (!url_string) {
|
||||||
promise.RejectWithErrorMessage("Missing required option 'url'");
|
promise.RejectWithErrorMessage("Missing required option 'url'");
|
||||||
|
return handle;
|
||||||
}
|
}
|
||||||
const std::string* name = details.FindStringKey("name");
|
const std::string* name = details.FindStringKey("name");
|
||||||
const std::string* value = details.FindStringKey("value");
|
const std::string* value = details.FindStringKey("value");
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue