Merge branch 'ChristianPauly-master-patch-10922' into 'master'

Fix getBody method.

See merge request famedly/famedlysdk!8
This commit is contained in:
Christian 2019-06-12 06:22:30 +00:00
commit 96b83d8841

View file

@ -73,7 +73,11 @@ class Event {
String get formattedText => content["formatted_body"] ?? ""; String get formattedText => content["formatted_body"] ?? "";
/// Use this to get the body. /// Use this to get the body.
String getBody () => formattedText ?? text ?? "*** Unable to parse Content ***"; String getBody () {
if (formattedText != "") return formattedText;
if (text != "") return text;
return "*** Unable to parse Content ***";
}
/// Get the real type. /// Get the real type.
EventTypes get type { EventTypes get type {