We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 3524946 commit e67ebb7Copy full SHA for e67ebb7
modules/angular2/src/facade/lang.dart
@@ -30,7 +30,15 @@ bool isPromise(obj) => obj is Future;
30
bool isNumber(obj) => obj is num;
31
bool isDate(obj) => obj is DateTime;
32
33
-String stringify(obj) => obj.toString();
+String stringify(obj) {
34
+ final exp = new RegExp(r"from Function '(\w+)'");
35
+ final str = obj.toString();
36
+ if (exp.firstMatch(str) != null) {
37
+ return exp.firstMatch(str).group(1);
38
+ } else {
39
+ return str;
40
+ }
41
+}
42
43
int serializeEnum(val) {
44
return val.index;
0 commit comments