Skip to content

Commit

Permalink
chore: use SetGetter to serialize the render_frame_host
Browse files Browse the repository at this point in the history
Co-authored-by: Samuel Maddock <samuel.maddock@gmail.com>
  • Loading branch information
jkleinsc and samuelmaddock committed May 17, 2022
1 parent 26087ec commit c394da3
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions shell/browser/hid/hid_chooser_context.cc
Expand Up @@ -123,10 +123,10 @@ void HidChooserContext::RevokeDevicePermission(
if (session) {
v8::Isolate* isolate = JavascriptEnvironment::GetIsolate();
v8::HandleScope scope(isolate);
v8::Local<v8::Object> details = gin::DataObjectBuilder(isolate)
.Set("device", device.Clone())
.Set("frame", render_frame_host)
.Build();
gin_helper::Dictionary details =
gin_helper::Dictionary::CreateEmpty(isolate);
details.Set("device", device.Clone());
details.SetGetter("frame", render_frame_host);
session->Emit("hid-device-revoked", details);
}
}
Expand Down

0 comments on commit c394da3

Please sign in to comment.