File tree Expand file tree Collapse file tree 5 files changed +10
-6
lines changed Expand file tree Collapse file tree 5 files changed +10
-6
lines changed Original file line number Diff line number Diff line change 1+ ## [ 3.0.2] - 2021-12-19
2+
3+ * Update Readme
4+
15## [ 3.0.1] - 2021-12-18
26
37* Gracefully handle bad responses
Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ In your flutter project add the dependency:
1515``` dart
1616dependencies:
1717 ...
18- woosignal: ^3.0.1
18+ woosignal: ^3.0.2
1919```
2020
2121### Usage example #
@@ -35,7 +35,7 @@ import 'package:woosignal/woosignal.dart';
3535_getProducts() async {
3636
3737 // Step 1 - Initialize WooSignal
38- WooSignal wooSignal = await WooSignal.instance.init(appKey: "your app key");
38+ await WooSignal.instance.init(appKey: "your app key");
3939
4040 // Step 2 - Call an API
4141 List<Product> products = await WooSignal.instance.getProducts();
Original file line number Diff line number Diff line change @@ -31,9 +31,9 @@ class _MyHomePageState extends State<MyHomePage> {
3131
3232 _incrementCounter () async {
3333 // CREATING AN INSTANCE FOR WOOSIGNAL
34- WooSignal wooSignal = await WooSignal .instance.init (appKey: "your app key" );
34+ await WooSignal .instance.init (appKey: "your app key" );
3535
36- List <Product > products = await wooSignal .getProducts ();
36+ List <Product > products = await WooSignal .instance .getProducts ();
3737 if (products.isNotEmpty) {
3838 _productName = products[0 ].name ?? "" ;
3939 }
Original file line number Diff line number Diff line change @@ -59,7 +59,7 @@ class WooSignal {
5959 bool ? _debugMode;
6060
6161 /// Initialize the class
62- Future init ({required String ? appKey, bool debugMode = false }) async {
62+ Future < void > init ({required String ? appKey, bool debugMode = false }) async {
6363 assert (appKey != null && appKey != "" ,
6464 "Provide a valid app key. Visit https://woosignal.com" );
6565 _apiProvider = ApiProvider (appKey: appKey! , debugMode: debugMode);
Original file line number Diff line number Diff line change 11name : woosignal
22description : WooCommerce REST API for dart, connect a WooCommerce store and start developing with our interface for their API endpoints.
3- version : 3.0.1
3+ version : 3.0.2
44homepage : https://woosignal.com
55repository : https://github.com/woosignal/flutter-woocommerce-api
66issue_tracker : https://github.com/woosignal/flutter-woocommerce-api/issues
You can’t perform that action at this time.
0 commit comments