TF-1487 Apply linter rule
This commit is contained in:
@@ -18,27 +18,21 @@ class CacheFCMDatasourceImpl extends FCMDatasource {
|
||||
Future<bool> storeStateToRefresh(TypeName typeName, jmap.State newState) {
|
||||
return Future.sync(() async {
|
||||
return await _firebaseCacheManager.storeStateToRefresh(typeName, newState);
|
||||
}).catchError((error) {
|
||||
_exceptionThrower.throwException(error);
|
||||
});
|
||||
}).catchError(_exceptionThrower.throwException);
|
||||
}
|
||||
|
||||
@override
|
||||
Future<jmap.State> getStateToRefresh(TypeName typeName) {
|
||||
return Future.sync(() async {
|
||||
return await _firebaseCacheManager.getStateToRefresh(typeName);
|
||||
}).catchError((error) {
|
||||
_exceptionThrower.throwException(error);
|
||||
});
|
||||
}).catchError(_exceptionThrower.throwException);
|
||||
}
|
||||
|
||||
@override
|
||||
Future<bool> deleteStateToRefresh(TypeName typeName) {
|
||||
return Future.sync(() async {
|
||||
return await _firebaseCacheManager.deleteStateToRefresh(typeName);
|
||||
}).catchError((error) {
|
||||
_exceptionThrower.throwException(error);
|
||||
});
|
||||
}).catchError(_exceptionThrower.throwException);
|
||||
}
|
||||
|
||||
@override
|
||||
@@ -64,9 +58,7 @@ class CacheFCMDatasourceImpl extends FCMDatasource {
|
||||
Future<FCMSubscriptionCache> geSubscription() {
|
||||
return Future.sync(() async {
|
||||
return await _firebaseCacheManager.getSubscription();
|
||||
}).catchError((error) {
|
||||
_exceptionThrower.throwException(error);
|
||||
});
|
||||
}).catchError(_exceptionThrower.throwException);
|
||||
}
|
||||
|
||||
@override
|
||||
|
||||
@@ -19,9 +19,7 @@ class FcmDatasourceImpl extends FCMDatasource {
|
||||
Future<FirebaseSubscription> getFirebaseSubscriptionByDeviceId(String deviceId) {
|
||||
return Future.sync(() async {
|
||||
return await _fcmApi.getFirebaseSubscriptionByDeviceId(deviceId);
|
||||
}).catchError((error) {
|
||||
_exceptionThrower.throwException(error);
|
||||
});
|
||||
}).catchError(_exceptionThrower.throwException);
|
||||
}
|
||||
|
||||
@override
|
||||
@@ -44,9 +42,7 @@ class FcmDatasourceImpl extends FCMDatasource {
|
||||
return Future.sync(() async {
|
||||
final firebaseSubscription = await _fcmApi.registerNewToken(newTokenRequest);
|
||||
return firebaseSubscription.fromDeviceId(newDeviceId: newTokenRequest.firebaseSubscription.deviceClientId);
|
||||
}).catchError((error) {
|
||||
_exceptionThrower.throwException(error);
|
||||
});
|
||||
}).catchError(_exceptionThrower.throwException);
|
||||
}
|
||||
|
||||
@override
|
||||
@@ -63,8 +59,6 @@ class FcmDatasourceImpl extends FCMDatasource {
|
||||
Future<bool> destroySubscription(String subscriptionId) {
|
||||
return Future.sync(() async {
|
||||
return await _fcmApi.destroySubscription(subscriptionId);
|
||||
}).catchError((error) {
|
||||
_exceptionThrower.throwException(error);
|
||||
});
|
||||
}).catchError(_exceptionThrower.throwException);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user