Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2379)

Unified Diff: chrome/renderer/resources/extensions/last_error.js

Issue 10748011: Fix to problem of chrome.runtime sometimes not being defined. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: single quotes Created 8 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/renderer/resources/extensions/last_error.js
diff --git a/chrome/renderer/resources/extensions/last_error.js b/chrome/renderer/resources/extensions/last_error.js
index 66f69f5150da75d238126cfa15b1681d4b507b90..2b38a2910e4a5dfa9b0acef1a246ed6c042ffd73 100644
--- a/chrome/renderer/resources/extensions/last_error.js
+++ b/chrome/renderer/resources/extensions/last_error.js
@@ -2,8 +2,10 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+requireNative('runtime');
+
function set(message) {
- var errorObject = { "message": message };
+ var errorObject = { 'message': message };
if (chrome.extension)
chrome.extension.lastError = errorObject;
chrome.runtime.lastError = errorObject;
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698