Skip to content

Commit

Permalink
Merge pull request #77 from 3Dpass/dev
Browse files Browse the repository at this point in the history
feat: Expandable objects & putObject update. Version 2.17.2
  • Loading branch information
L3odr0id authored Nov 6, 2024
2 parents 7f219d7 + fed6b45 commit 2e954f0
Show file tree
Hide file tree
Showing 110 changed files with 1,586 additions and 1,728 deletions.
8 changes: 6 additions & 2 deletions android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,11 @@ android {

applicationVariants.configureEach { variant ->
variant.outputs.configureEach { output ->
outputFileName = "threedpass" + "-" + versionName + "-" + output.getFilter(com.android.build.OutputFile.ABI) + ".apk"
def abiFilter = output.getFilter(com.android.build.OutputFile.ABI)
def abiVariant = abiFilter != null ? abiFilter : "universal"
// def abiFilter = output.variantOutputConfiguration.filters.find { it.filterType == FilterConfiguration.FilterType.ABI }
// def abiVariant = abiFilter != null ? abiFilter.identifier : "universal"
outputFileName = "threedpass" + "-" + versionName + "-" + abiVariant + ".apk"
}
}
}
Expand All @@ -113,5 +117,5 @@ flutter {
}

dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
// implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
}
8 changes: 6 additions & 2 deletions assets/translations/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -334,7 +334,7 @@
"from_address_dropdown_hint": "Choose account",
"poscan_putobject_choose_napprovals": "nApprovals",
"poscan_putobject_choose_hashes": "Hashes",
"poscan_putobject_fees_warning": "This transaction takes 100+ P3D",
"poscan_putobject_fees_warning": "This transaction takes fees",
"poscan_putobject_choose_properties": "Properties (optional)",
"PROPERTIES_number_plural": {
"zero": "0 properties chosen",
Expand Down Expand Up @@ -540,5 +540,9 @@
"other": "assets"
},
"linked_snapshots_helper": "+ {} found",
"view_object": "View object"
"view_object": "View object",

"@2.17.2": {},
"create_atomic_swap_choose_account_label": "Choose account",
"put_object_is_private_flag": "Is private"
}
24 changes: 0 additions & 24 deletions lib/core/architecture/get_data_usecase.dart

This file was deleted.

7 changes: 0 additions & 7 deletions lib/core/architecture/local_repository_interface.dart

This file was deleted.

3 changes: 0 additions & 3 deletions lib/core/architecture/remote_repository_interface.dart

This file was deleted.

9 changes: 0 additions & 9 deletions lib/core/errors/storage_error.dart

This file was deleted.

280 changes: 0 additions & 280 deletions lib/core/errors/storage_error.freezed.dart

This file was deleted.

File renamed without changes.
9 changes: 5 additions & 4 deletions lib/core/persistence/hive_universal_store.dart
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import 'package:hive_flutter/hive_flutter.dart';
import 'package:threedpass/core/errors/storage_error.dart';
import 'package:threedpass/core/utils/logger.dart';

class HiveUniversalStore<T> {
Expand All @@ -20,17 +19,19 @@ class HiveUniversalStore<T> {
}

/// Delete object by unknown key
Future<StorageError?> removeObject(final T value) async {
Future<void> removeObject(final T value) async {
final map = _box.toMap();
final dynamic key = map.keys
.firstWhere((final dynamic k) => map[k] == value, orElse: () => null);

if (key != null) {
await _box.delete(key);
await _box.flush();
return null;
return;
} else {
logger.e("Couldn't find object $value to remove");
throw Exception("Couldn't find object $value to remove");
}
return const StorageError.impossibleOperation();
}

// Future<void> removeAll() async {
Expand Down
Loading

0 comments on commit 2e954f0

Please sign in to comment.