Skip to content

Commit 1f208aa

Browse files
[in_app_purchase] Minor lint cleanup (#4818)
Updates some lints for current versions of Flutter, reducing the need for `// ignore`s. Fixes flutter/flutter#131792
1 parent 200e3c6 commit 1f208aa

File tree

13 files changed

+22
-29
lines changed

13 files changed

+22
-29
lines changed

packages/in_app_purchase/in_app_purchase/CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
## 3.1.10
2+
3+
* Updates example code for current versions of Flutter.
4+
15
## 3.1.9
26

37
* Adds pub topics to package metadata.

packages/in_app_purchase/in_app_purchase/example/lib/main.dart

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -164,10 +164,8 @@ class _MyAppState extends State<_MyApp> {
164164
}
165165
if (_purchasePending) {
166166
stack.add(
167-
// TODO(goderbauer): Make this const when that's available on stable.
168-
// ignore: prefer_const_constructors
169-
Stack(
170-
children: const <Widget>[
167+
const Stack(
168+
children: <Widget>[
171169
Opacity(
172170
opacity: 0.3,
173171
child: ModalBarrier(dismissible: false, color: Colors.grey),

packages/in_app_purchase/in_app_purchase/pubspec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: in_app_purchase
22
description: A Flutter plugin for in-app purchases. Exposes APIs for making in-app purchases through the App Store and Google Play.
33
repository: https://github.com/flutter/packages/tree/main/packages/in_app_purchase/in_app_purchase
44
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+in_app_purchase%22
5-
version: 3.1.9
5+
version: 3.1.10
66

77
environment:
88
sdk: ">=2.19.0 <4.0.0"

packages/in_app_purchase/in_app_purchase_android/CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
## 0.3.0+13
2+
3+
* Updates example code for current versions of Flutter.
4+
15
## 0.3.0+12
26

37
* Adds pub topics to package metadata.

packages/in_app_purchase/in_app_purchase_android/example/lib/main.dart

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,6 @@
22
// Use of this source code is governed by a BSD-style license that can be
33
// found in the LICENSE file.
44

5-
// ignore_for_file: avoid_print
6-
75
import 'dart:async';
86

97
import 'package:flutter/material.dart';
@@ -156,10 +154,8 @@ class _MyAppState extends State<_MyApp> {
156154
}
157155
if (_purchasePending) {
158156
stack.add(
159-
// TODO(goderbauer): Make this const when that's available on stable.
160-
// ignore: prefer_const_constructors
161-
Stack(
162-
children: const <Widget>[
157+
const Stack(
158+
children: <Widget>[
163159
Opacity(
164160
opacity: 0.3,
165161
child: ModalBarrier(dismissible: false, color: Colors.grey),

packages/in_app_purchase/in_app_purchase_android/lib/src/in_app_purchase_android_platform_addition.dart

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ class InAppPurchaseAndroidPlatformAddition
2222
/// this is handled internally and the [enablePendingPurchase] property will
2323
/// always return `true`.
2424
///
25-
// ignore: deprecated_member_use_from_same_package
2625
/// See also [enablePendingPurchases] for more on pending purchases.
2726
@Deprecated(
2827
'The requirement to call `enablePendingPurchases()` has become obsolete '

packages/in_app_purchase/in_app_purchase_android/pubspec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: in_app_purchase_android
22
description: An implementation for the Android platform of the Flutter `in_app_purchase` plugin. This uses the Android BillingClient APIs.
33
repository: https://github.com/flutter/packages/tree/main/packages/in_app_purchase/in_app_purchase_android
44
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+in_app_purchase%22
5-
version: 0.3.0+12
5+
version: 0.3.0+13
66

77
environment:
88
sdk: ">=2.19.0 <4.0.0"

packages/in_app_purchase/in_app_purchase_platform_interface/test/in_app_purchase_platform_test.dart

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,6 @@ void main() {
3333
});
3434

3535
test(
36-
// ignore: lines_longer_than_80_chars
3736
'Default implementation of purchaseStream should throw unimplemented error',
3837
() {
3938
final ExtendsInAppPurchasePlatform inAppPurchasePlatform =
@@ -46,7 +45,6 @@ void main() {
4645
});
4746

4847
test(
49-
// ignore: lines_longer_than_80_chars
5048
'Default implementation of isAvailable should throw unimplemented error',
5149
() {
5250
final ExtendsInAppPurchasePlatform inAppPurchasePlatform =
@@ -59,7 +57,6 @@ void main() {
5957
});
6058

6159
test(
62-
// ignore: lines_longer_than_80_chars
6360
'Default implementation of queryProductDetails should throw unimplemented error',
6461
() {
6562
final ExtendsInAppPurchasePlatform inAppPurchasePlatform =
@@ -72,7 +69,6 @@ void main() {
7269
});
7370

7471
test(
75-
// ignore: lines_longer_than_80_chars
7672
'Default implementation of buyNonConsumable should throw unimplemented error',
7773
() {
7874
final ExtendsInAppPurchasePlatform inAppPurchasePlatform =
@@ -87,7 +83,6 @@ void main() {
8783
});
8884

8985
test(
90-
// ignore: lines_longer_than_80_chars
9186
'Default implementation of buyConsumable should throw unimplemented error',
9287
() {
9388
final ExtendsInAppPurchasePlatform inAppPurchasePlatform =
@@ -102,7 +97,6 @@ void main() {
10297
});
10398

10499
test(
105-
// ignore: lines_longer_than_80_chars
106100
'Default implementation of completePurchase should throw unimplemented error',
107101
() {
108102
final ExtendsInAppPurchasePlatform inAppPurchasePlatform =
@@ -115,7 +109,6 @@ void main() {
115109
});
116110

117111
test(
118-
// ignore: lines_longer_than_80_chars
119112
'Default implementation of restorePurchases should throw unimplemented error',
120113
() {
121114
final ExtendsInAppPurchasePlatform inAppPurchasePlatform =

packages/in_app_purchase/in_app_purchase_storekit/CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
## 0.3.6+7
2+
3+
* Updates example code for current versions of Flutter.
4+
15
## 0.3.6+6
26

37
* Adds pub topics to package metadata.

packages/in_app_purchase/in_app_purchase_storekit/example/lib/main.dart

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -156,10 +156,8 @@ class _MyAppState extends State<_MyApp> {
156156
}
157157
if (_purchasePending) {
158158
stack.add(
159-
// TODO(goderbauer): Make this const when that's available on stable.
160-
// ignore: prefer_const_constructors
161-
Stack(
162-
children: const <Widget>[
159+
const Stack(
160+
children: <Widget>[
163161
Opacity(
164162
opacity: 0.3,
165163
child: ModalBarrier(dismissible: false, color: Colors.grey),

0 commit comments

Comments
 (0)