Skip to content

Commit

Permalink
Merge pull request #142 from nimblehq/chore/bring-hotfix-1.3.1-to-dev…
Browse files Browse the repository at this point in the history
…elop

[Chore] Bring Hotfix 1.3.1 to develop
  • Loading branch information
luongvo authored Jan 13, 2023
2 parents f731d2f + eebb127 commit cc7a175
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 5 deletions.
6 changes: 5 additions & 1 deletion .template/lib/di/interceptor/app_interceptor.dart
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,12 @@ import 'package:dio/dio.dart';

class AppInterceptor extends Interceptor {
final bool _requireAuthenticate;
final Dio _dio;

AppInterceptor(this._requireAuthenticate);
AppInterceptor(
this._requireAuthenticate,
this._dio,
);

@override
Future onRequest(
Expand Down
5 changes: 4 additions & 1 deletion .template/lib/di/provider/dio_provider.dart
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,10 @@ class DioProvider {

Dio _createDio({bool requireAuthenticate = false}) {
final dio = Dio();
final appInterceptor = AppInterceptor(requireAuthenticate);
final appInterceptor = AppInterceptor(
requireAuthenticate,
dio,
);
final interceptors = <Interceptor>[];
interceptors.add(appInterceptor);
if (!kReleaseMode) {
Expand Down
2 changes: 0 additions & 2 deletions .template/lib/utils/wrappers/permission_wrapper.dart
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import 'package:injectable/injectable.dart';
import 'package:permission_handler/permission_handler.dart'
as permission_handler;

Expand All @@ -10,7 +9,6 @@ abstract class PermissionWrapper {
Future<bool> isCameraPermissionPermanentlyDenied();
}

@Singleton(as: PermissionWrapper)
class PermissionWrapperImpl extends PermissionWrapper {
@override
Future<bool> requestCameraPermission() {
Expand Down
2 changes: 1 addition & 1 deletion .template/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ publish_to: 'none' # Remove this line if you wish to publish to pub.dev
# In iOS, build-name is used as CFBundleShortVersionString while build-number used as CFBundleVersion.
# Read more about iOS versioning at
# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
version: 1.4.0+13
version: 1.4.0+14

environment:
sdk: ">=2.17.5 <3.0.0"
Expand Down

0 comments on commit cc7a175

Please sign in to comment.