### Preflight Checklist

I have read the [Contributing Guidelines](https://github.com/electron/electron/blob/master/CONTRIBUTING.md) for this project.
I agree to follow the [Code of Conduct](https://github.com/electron/electron/blob/master/CODE_OF_CONDUCT.md) that this project adheres to.
I have searched the [issue tracker](https://www.github.com/electron/electron/issues) for a feature request that matches the one I want to file, without success.

### Electron Version

12.0.2

### What operating system are you using?

macOS

### Operating System Version

macOS Catalina 10.15.7

### What arch are you using?

x64

### Last Known Working Electron version

_No response_

### Expected Behavior

Returning an invalid serial port ID in the callback of the `select-serial-port` event handler of `session` should not crash Electron.

### Actual Behavior

Returning an invalid serial port ID in the callback of the `select-serial-port` event handler of `session` crashes Electron with a SIGSEGV. Calling the callback with `"foo"` or any string that is clearly not a valid serial port ID is enough to trigger the bug. Valid serial port IDs and empty strings work as expected.

### Testcase Gist URL

_No response_


shell/browser/serial/serial_chooser_controller.cc
#elif defined(OS_WIN)
    if (!port->device_instance_id.empty()) {
      dict.Set("deviceInstanceId", port->device_instance_id);
    }
#endif
    return gin::ConvertToV8(isolate, dict);
  }
};
}  
namespace electron {
SerialChooserController::SerialChooserController(
    content::RenderFrameHost* render_frame_host,
    std::vector<blink::mojom::SerialPortFilterPtr> filters,
    content::SerialChooser::Callback callback,
    content::WebContents* web_contents,
    base::WeakPtr<ElectronSerialDelegate> serial_delegate)
    : WebContentsObserver(web_contents),
      filters_(std::move(filters)),
      callback_(std::move(callback)),
      serial_delegate_(serial_delegate) {
  requesting_origin_ = render_frame_host->GetLastCommittedOrigin();
  embedding_origin_ = web_contents->GetMainFrame()->GetLastCommittedOrigin();
  chooser_context_ = SerialChooserContextFactory::GetForBrowserContext(
                         web_contents->GetBrowserContext())
                         ->AsWeakPtr();
  DCHECK(chooser_context_);
  chooser_context_->GetPortManager()->GetDevices(base::BindOnce(
      &SerialChooserController::OnGetDevices, weak_factory_.GetWeakPtr()));
}
SerialChooserController::~SerialChooserController() {