From 977d27bef9e489ab1550792b9da89116c9734e23 Mon Sep 17 00:00:00 2001 From: Sam Rawlins Date: Tue, 24 Sep 2024 09:32:54 -0700 Subject: [PATCH] Prepare for curly_braces lint rule change To fix https://github.com/dart-lang/linter/issues/4870, the analyzer is now reporting if-statement bodies without curly braces when the if-statement condition spans multiple lines. This change prepares zulip-flutter for this lint rule change. --- lib/model/content.dart | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/model/content.dart b/lib/model/content.dart index e99d4d391a..64aa5a4bd9 100644 --- a/lib/model/content.dart +++ b/lib/model/content.dart @@ -995,7 +995,9 @@ class _ZulipContentParser { final first = child.nodes[0]; if (first is! dom.Element || first.localName != 'span' - || first.nodes.isNotEmpty) return null; + || first.nodes.isNotEmpty) { + return null; + } } final grandchild = child.nodes.last; if (grandchild is! dom.Element) return null;