mirror of
https://github.com/immich-app/immich.git
synced 2024-12-28 22:51:59 +00:00
15c04d3056
* refactor(mobile): DB repository for asset, backup, sync service * review feedback * fix bug found by Alex --------- Co-authored-by: Alex <alex.tran1502@gmail.com>
9 lines
254 B
Dart
9 lines
254 B
Dart
import 'package:immich_mobile/constants/errors.dart';
|
|
|
|
abstract class ApiRepository {
|
|
Future<T> checkNull<T>(Future<T?> future) async {
|
|
final response = await future;
|
|
if (response == null) throw NoResponseDtoError();
|
|
return response;
|
|
}
|
|
}
|