-
Notifications
You must be signed in to change notification settings - Fork 9.8k
[file_selector] Use const instead of final for XTypeGroup. #6542
[file_selector] Use const instead of final for XTypeGroup. #6542
Conversation
Version pump for file_selector_platform_interface
Version pump for file_selector_platform_interface
Version pump for file_selector_platform_interface
Version pump for file_selector_platform_interface
Version pump for file_selector_platform_interface
Version pump for file_selector_platform_interface
@@ -1,3 +1,7 @@ | |||
## NEXT | |||
|
|||
* Changes XTypeGroup initialization from final to const. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This test-only change doesn't need a CHANGELOG entry, so this file can be reverted.
@@ -14,15 +11,9 @@ void main() { | |||
group('acceptedTypesToString', () { | |||
test('works', () { | |||
final List<XTypeGroup> acceptedTypes = <XTypeGroup>[ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Throughout the changes in this package, can't these lists be const instead of each item in the list?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, you are right. It's doable and better.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
@ditman for second approval
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would @cbracken for second approval do?
It'll do in a pinch 😉 Thanks! |
This is the final step of this issue, removing all the
//ignore
's that were added and converting XTypeGroup toconst
instead offinal
.The version of
file_selector_platform_interface
was upgraded to 2.2.0 in thepubspec.yaml
for all the platforms.Issue:
#111906 [file_selector]
XTypeGroup
should be immutableRelated PR's:
#6476 Convert XTypeGroup to const
#6463 Annotate all creation of XTypeGroup with // ignore: prefer_const_contructor
Pre-launch Checklist
dart format
.)[shared_preferences]
pubspec.yaml
with an appropriate new version according to the pub versioning philosophy, or this PR is exempt from version changes.CHANGELOG.md
to add a description of the change, following repository CHANGELOG style.///
).If you need help, consider asking for advice on the #hackers-new channel on Discord.