mirror of
https://github.com/flutter/flutter
synced 2024-10-14 04:02:56 +00:00
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.
This commit is contained in:
parent
eba6ceb85d
commit
eae9e053e3
|
@ -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<dynamic> delegate) => delegate is LocalizationsDelegate<WidgetsLocalizations>));
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue