File tree Expand file tree Collapse file tree 1 file changed +10
-6
lines changed Expand file tree Collapse file tree 1 file changed +10
-6
lines changed Original file line number Diff line number Diff line change @@ -654,12 +654,16 @@ class Debugger extends Domain {
654
654
}
655
655
}
656
656
657
- bool isNativeJsObject (InstanceRef instanceRef) =>
658
- // New type representation of JS objects reifies them to JavaScriptObject.
659
- (instanceRef? .classRef? .name == 'JavaScriptObject' &&
660
- instanceRef? .classRef? .library? .uri == 'dart:_interceptors' ) ||
661
- // Old type representation still needed to support older SDK versions.
662
- instanceRef? .classRef? .name == 'NativeJavaScriptObject' ;
657
+ bool isNativeJsObject (InstanceRef instanceRef) {
658
+ // New type representation of JS objects reifies them to a type suffixed with
659
+ // JavaScriptObject.
660
+ var className = instanceRef? .classRef? .name;
661
+ return (className != null &&
662
+ className.endsWith ('JavaScriptObject' ) &&
663
+ instanceRef? .classRef? .library? .uri == 'dart:_interceptors' ) ||
664
+ // Old type representation still needed to support older SDK versions.
665
+ className == 'NativeJavaScriptObject' ;
666
+ }
663
667
664
668
/// Returns the Dart line number for the provided breakpoint.
665
669
int _lineNumberFor (Breakpoint breakpoint) =>
You can’t perform that action at this time.
0 commit comments