| Index: frog/corejs.dart
|
| diff --git a/frog/corejs.dart b/frog/corejs.dart
|
| index bfa0875c0f5ce9743452b5d5b8df3510cad661b7..4b58b2e3d0c00d9f481f4894655223a7f861fd6c 100644
|
| --- a/frog/corejs.dart
|
| +++ b/frog/corejs.dart
|
| @@ -287,12 +287,10 @@ function $toDartException(e) {
|
|
|
| if (useNotNullBool) {
|
| useThrow = true;
|
| + // Some testing showed that this patterned fared well across browsers.
|
| w.writeln(@"""
|
| function $notnull_bool(test) {
|
| - if (test == null || typeof(test) != 'boolean') {
|
| - $throw(new TypeError('must be "true" or "false"'));
|
| - }
|
| - return test === true;
|
| + return typeof(test) == 'boolean' ? test : test.is$bool();
|
| }""");
|
| }
|
|
|
|
|