diff --git a/atom/browser/api/atom_api_app.cc b/atom/browser/api/atom_api_app.cc index 5228c640f003..4f926f55ba73 100644 --- a/atom/browser/api/atom_api_app.cc +++ b/atom/browser/api/atom_api_app.cc @@ -168,13 +168,12 @@ void OnClientCertificateSelected( return; } - v8::Local data; + std::string data; if (!cert_data.Get("data", &data)) return; auto certs = net::X509Certificate::CreateCertificateListFromBytes( - node::Buffer::Data(data), node::Buffer::Length(data), - net::X509Certificate::FORMAT_AUTO); + data.c_str(), data.length(), net::X509Certificate::FORMAT_AUTO); if (certs.size() > 0) delegate->ContinueWithCertificate(certs[0].get()); }