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

Unified Diff: pkg/dev_compiler/lib/js/common/dart_sdk.js

Issue 2334763002: Testing support for FF and Safari (Closed)
Patch Set: Created 4 years, 3 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:
Download patch
Index: pkg/dev_compiler/lib/js/common/dart_sdk.js
diff --git a/pkg/dev_compiler/lib/js/common/dart_sdk.js b/pkg/dev_compiler/lib/js/common/dart_sdk.js
index f8258be836f3ef50351c2721accf18524f46a6e4..1b39b697b1cb5d79f66dd7fcabf796d40cf6624e 100644
--- a/pkg/dev_compiler/lib/js/common/dart_sdk.js
+++ b/pkg/dev_compiler/lib/js/common/dart_sdk.js
@@ -1021,6 +1021,7 @@
if (!jsType) return;
let extProto = dartExtType.prototype;
let jsProto = jsType.prototype;
+ if (!jsProto) return;
jsProto[dart._extensionType] = dartExtType;
dart._installProperties(jsProto, extProto);
let originalSigFn = dart.getOwnPropertyDescriptor(dartExtType, dart._methodSig).get;
@@ -1761,7 +1762,7 @@
};
dart.nullSafe = function(obj, ...callbacks) {
if (obj == null) return obj;
- for (const callback of callbacks) {
+ for (let callback of callbacks) {
obj = callback(obj);
if (obj == null) break;
}

Powered by Google App Engine
This is Rietveld 408576698