fix: Flutter Hive on Linux

onboarding
Christian Pauly 4 years ago
parent ece1f6dc1b
commit 9a8c376d91

1
.gitignore vendored

@ -5,6 +5,7 @@
*.swp
*.snap
.DS_Store
.local/
.atom/
.buildlog/
.history

@ -24,7 +24,11 @@ class FlutterFamedlySdkHiveDatabase extends FamedlySdkHiveDatabase {
Client client) async {
if (!kIsWeb && !_hiveInitialized) {
Logs().i('Init Hive database...');
await Hive.initFlutter();
if (!kIsWeb && Platform.isLinux) {
Hive.init('.local/share/fluffychat/');
} else {
await Hive.initFlutter();
}
_hiveInitialized = true;
}
HiveCipher hiverCipher;

Loading…
Cancel
Save