diff --git a/.flutter-plugins-dependencies b/.flutter-plugins-dependencies index 7a5476c..0143ae3 100644 --- a/.flutter-plugins-dependencies +++ b/.flutter-plugins-dependencies @@ -1 +1 @@ -{"info":"This is a generated file; do not edit or check into version control.","plugins":{"ios":[{"name":"connectivity_plus","path":"/home/saif/.pub-cache/hosted/pub.dev/connectivity_plus-6.1.3/","native_build":true,"dependencies":[]}],"android":[{"name":"connectivity_plus","path":"/home/saif/.pub-cache/hosted/pub.dev/connectivity_plus-6.1.3/","native_build":true,"dependencies":[]}],"macos":[{"name":"connectivity_plus","path":"/home/saif/.pub-cache/hosted/pub.dev/connectivity_plus-6.1.3/","native_build":true,"dependencies":[]}],"linux":[{"name":"connectivity_plus","path":"/home/saif/.pub-cache/hosted/pub.dev/connectivity_plus-6.1.3/","native_build":false,"dependencies":[]}],"windows":[{"name":"connectivity_plus","path":"/home/saif/.pub-cache/hosted/pub.dev/connectivity_plus-6.1.3/","native_build":true,"dependencies":[]}],"web":[{"name":"connectivity_plus","path":"/home/saif/.pub-cache/hosted/pub.dev/connectivity_plus-6.1.3/","dependencies":[]}]},"dependencyGraph":[{"name":"connectivity_plus","dependencies":[]}],"date_created":"2025-03-19 16:24:16.152213","version":"3.24.5","swift_package_manager_enabled":false} \ No newline at end of file +{"info":"This is a generated file; do not edit or check into version control.","plugins":{"ios":[{"name":"connectivity_plus","path":"/home/saif/.pub-cache/hosted/pub.dev/connectivity_plus-6.1.3/","native_build":true,"dependencies":[]}],"android":[{"name":"connectivity_plus","path":"/home/saif/.pub-cache/hosted/pub.dev/connectivity_plus-6.1.3/","native_build":true,"dependencies":[]}],"macos":[{"name":"connectivity_plus","path":"/home/saif/.pub-cache/hosted/pub.dev/connectivity_plus-6.1.3/","native_build":true,"dependencies":[]}],"linux":[{"name":"connectivity_plus","path":"/home/saif/.pub-cache/hosted/pub.dev/connectivity_plus-6.1.3/","native_build":false,"dependencies":[]}],"windows":[{"name":"connectivity_plus","path":"/home/saif/.pub-cache/hosted/pub.dev/connectivity_plus-6.1.3/","native_build":true,"dependencies":[]}],"web":[{"name":"connectivity_plus","path":"/home/saif/.pub-cache/hosted/pub.dev/connectivity_plus-6.1.3/","dependencies":[]}]},"dependencyGraph":[{"name":"connectivity_plus","dependencies":[]}],"date_created":"2025-03-21 11:24:51.253806","version":"3.24.5","swift_package_manager_enabled":false} \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md index 2225c6f..1cc2fee 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,8 @@ +## 2.1.8 + +- code refactoring for cleaner code +- updated pubspec.yaml + ## 2.1.7 - updated readme.md diff --git a/lib/src/dio_simple_serializer.dart b/lib/src/dio_simple_serializer.dart index 330e3f1..201ce04 100644 --- a/lib/src/dio_simple_serializer.dart +++ b/lib/src/dio_simple_serializer.dart @@ -50,7 +50,7 @@ class JsonSerializer implements DioSerializer { } SingleItemType _deserialize(dynamic singleItem) { - if(singleItem is SingleItemType) return singleItem; + if (singleItem is SingleItemType) return singleItem; return jsonParserMap[SingleItemType]!(singleItem); } } diff --git a/pubspec.yaml b/pubspec.yaml index 07a8afb..fc1bd1a 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,9 +1,9 @@ name: viva_network_kit description: A lightweight and developer-friendly network manager for Flutter, built on Dio, with automatic connectivity checks before every API request. -version: 2.1.7 +version: 2.1.8 homepage: https://vivasoftltd.com/ repository: https://github.com/vivasoft-ltd/flutter-network-kit -publish_to: pub.dev +issue_tracker: https://github.com/vivasoft-ltd/flutter-network-kit/issues environment: sdk: ">=2.17.0 <4.0.0" @@ -14,7 +14,7 @@ dependencies: sdk: flutter dio: ^5.8.0+1 dartz: ^0.10.1 - built_value: ^8.9.3 + built_value: ^8.9.5 connectivity_plus: ^6.1.3 get_it: ^8.0.3 built_collection: ^5.1.1 @@ -25,39 +25,12 @@ dev_dependencies: sdk: flutter flutter_lints: ^5.0.0 -# For information on the generic Dart part of this file, see the -# following page: https://dart.dev/tools/pub/pubspec -# The following section is specific to Flutter. flutter: - # To add assets to your package, add an assets section, like this: - # assets: - # - images/a_dot_burr.jpeg - # - images/a_dot_ham.jpeg - # - # For details regarding assets in packages, see - # https://flutter.dev/assets-and-images/#from-packages - # - # An image asset can refer to one or more resolution-specific "variants", see - # https://flutter.dev/assets-and-images/#resolution-aware. - - # To add custom fonts to your package, add a fonts section here, - # in this "flutter" section. Each entry in this list should have a - # "family" key with the font family name, and a "fonts" key with a - # list giving the asset and other descriptors for the font. For - # example: - # fonts: - # - family: Schyler - # fonts: - # - asset: fonts/Schyler-Regular.ttf - # - asset: fonts/Schyler-Italic.ttf - # style: italic - # - family: Trajan Pro - # fonts: - # - asset: fonts/TrajanPro.ttf - # - asset: fonts/TrajanPro_Bold.ttf - # weight: 700 - # - # For details regarding fonts in packages, see - # https://flutter.dev/custom-fonts/#from-packages +topics: + - dio + - http + - connectivity + + diff --git a/test/flutter_network_lib.dart b/test/flutter_network_lib.dart index e470e71..ee9468a 100644 --- a/test/flutter_network_lib.dart +++ b/test/flutter_network_lib.dart @@ -1,6 +1,3 @@ import 'package:flutter_test/flutter_test.dart'; - -void main() { - -} +void main() {}