Uncontroversial and backwards compatible 2.0 SDK fixes (#13723)

Small code changes as part of moving the framework SDK forward to a 2.0 dev version.
This commit is contained in:
Leaf Petersen
2017-12-21 13:39:03 -08:00
committed by GitHub
parent ecb708ee3a
commit b3cfa785c4
13 changed files with 38 additions and 39 deletions

View File

@@ -125,7 +125,7 @@ String _jsonToMap(dynamic json) {
if (json is Iterable)
return 'const <dynamic>[${json.map(_jsonToMap).join(',')}]';
if (json is Map) {
if (json is Map<String, dynamic>) {
final StringBuffer buffer = new StringBuffer('const <String, dynamic>{');
json.forEach((String key, dynamic value) {
buffer.writeln(_jsonToMapEntry(key, value));