From eae9e053e38f5efabd8f7ab07a962a0381893799 Mon Sep 17 00:00:00 2001 From: Mehmet Fidanboylu Date: Fri, 1 Sep 2017 10:15:29 -0700 Subject: [PATCH] Fix localizations so that extract_messages is happy. (#11894) extract_messages script currently fails to parse this file because of its use of static asserts, super and a ctr body. Since we already have an assert in the body, I think it is also more readable to put all of them together. _LocalizationScope follows the same pattern above. --- packages/flutter/lib/src/widgets/localizations.dart | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/flutter/lib/src/widgets/localizations.dart b/packages/flutter/lib/src/widgets/localizations.dart index 535d2898702..34ba4496ed7 100644 --- a/packages/flutter/lib/src/widgets/localizations.dart +++ b/packages/flutter/lib/src/widgets/localizations.dart @@ -289,9 +289,9 @@ class Localizations extends StatefulWidget { @required this.locale, @required this.delegates, this.child, - }) : assert(locale != null), - assert(delegates != null), - super(key: key) { + }) : super(key: key) { + assert(locale != null); + assert(delegates != null); assert(delegates.any((LocalizationsDelegate delegate) => delegate is LocalizationsDelegate)); }