getCode method
Must return AuthCode for its identifiying code
.
This must return an instance of AuthCode where AuthCode.code matches code
.
Return null if no matching code.
Implementation
@override
Future<AuthCode?> getCode(AuthServer server, String code) async {
final query = Query<ManagedAuthToken>(context)
..where((o) => o.code).equalTo(code);
final storage = await query.fetchOne();
return storage?.asAuthCode();
}