commit | ac0568320baf36189e33957bd6985cf71e754431 | [log] [tgz] |
---|---|---|
author | Charles Whitten <cwhitten@google.com> | Tue Nov 19 23:08:42 2019 +0000 |
committer | CQ bot account: commit-bot@chromium.org <commit-bot@chromium.org> | Tue Nov 19 23:08:42 2019 +0000 |
tree | ecf1a59c53d78832f772ada51a23561f6bd0c15a | |
parent | abf971a74118655cfdbcda0c78e1f865b73faa4e [diff] |
[Ermine] Prevent potential toDouble call on null This is to prevent behavior that caused fxb/41681 Change-Id: I6a54d111b1dd0e2f7e3f32a70ed351e9f5071e1f
diff --git a/session_shells/ermine/settings/lib/src/weather.dart b/session_shells/ermine/settings/lib/src/weather.dart index 9b26dff..01a6b94 100644 --- a/session_shells/ermine/settings/lib/src/weather.dart +++ b/session_shells/ermine/settings/lib/src/weather.dart
@@ -101,7 +101,7 @@ var properties = data['properties']; location ..observation = properties['textDescription'] - ..tempInDegrees = properties['temperature']['value'].toDouble(); + ..tempInDegrees = properties['temperature']['value']?.toDouble(); } // Read the string response from the [HttpClientResponse].