Skip to content

armgit / ente

Public Imported from GitHub
0

πŸ’š End-to-end encrypted cloud for everything.

Clean old method

laurenspriem5f75db4e1f22
diff --git a/mobile/lib/utils/cache_util.dart b/mobile/lib/utils/cache_util.dart
index 30cf761604..e3b6abdd98 100644
--- a/mobile/lib/utils/cache_util.dart
+++ b/mobile/lib/utils/cache_util.dart
@@ -43,24 +43,6 @@ Future<void> _writeToJsonFile<P>(Map<String, dynamic> args) async {
}
}
-Future<void> writeToJsonFileUTF16<P>(
- String filePath,
- P data,
- String Function(P) toJsonString,
-) async {
- try {
- final file = File(filePath);
- if (!file.existsSync()) {
- file.createSync(recursive: true);
- }
- final jsonString = toJsonString(data);
- final encodedData = jsonString.codeUnits; // UTF-16 encoding
- await file.writeAsBytes(encodedData);
- } catch (e, s) {
- _logger.severe("Error writing to JSON file with UTF-16", e, s);
- }
-}
-
/// Reads a JSON file from the specified path using the provided method, inside computer.
/// The method should decode the JSON string into an object.
/// The JSON string is expected to be UTF-8 encoded.