Handle null values in TextInputConfiguration.actionLabel JSON (flutter/engine#8377)

Fixes https://github.com/flutter/flutter/issues/29798
This commit is contained in:
Jason Simmons
2019-03-29 17:15:04 -07:00
committed by GitHub
parent f305a32f09
commit 7bdf7064c4

View File

@@ -242,7 +242,7 @@ public class TextInputChannel {
TextCapitalization.fromValue(json.getString("textCapitalization")),
InputType.fromJson(json.getJSONObject("inputType")),
inputAction,
json.optString("actionLabel")
json.isNull("actionLabel") ? null : json.getString("actionLabel")
);
}