mirror of
https://github.com/Yubico/yubioath-flutter.git
synced 2024-12-24 18:52:55 +03:00
23 lines
577 B
Dart
23 lines
577 B
Dart
import 'package:flutter_riverpod/flutter_riverpod.dart';
|
|
|
|
import '../oath/command_providers.dart';
|
|
import 'impl.dart';
|
|
|
|
class FOathApiImpl extends FOathApi {
|
|
final StateNotifierProviderRef _ref;
|
|
|
|
FOathApiImpl(this._ref) : super();
|
|
|
|
@override
|
|
Future<void> updateOathCredentials(String credentialListJson) async {
|
|
_ref
|
|
.read(androidCredentialsProvider.notifier)
|
|
.setFromString(credentialListJson);
|
|
}
|
|
|
|
@override
|
|
Future<void> updateSession(String sessionJson) async {
|
|
_ref.read(androidStateProvider.notifier).setFromString(sessionJson);
|
|
}
|
|
}
|