chore: Add error report for incorrect recovery key

This commit is contained in:
Krille 2023-11-24 15:36:41 +01:00
commit d8cc1bdf25
No known key found for this signature in database
3 changed files with 18 additions and 4 deletions

View file

@ -3,6 +3,7 @@ import 'dart:io';
import 'package:flutter/material.dart';
import 'package:flutter_gen/gen_l10n/l10n.dart';
import 'package:matrix/encryption.dart';
import 'package:matrix/matrix.dart';
import 'package:fluffychat/pages/tasks/tasks.dart';
@ -20,6 +21,9 @@ extension LocalizedExceptionExtension on Object {
return (this as MatrixException).errorMessage;
}
}
if (this is InvalidPassphraseException) {
return L10n.of(context)!.wrongRecoveryKey;
}
if (this is TodoListChangedException) {
return L10n.of(context)!.todoListChangedError;
}