mirror of
https://github.com/permissionlesstech/bitchat-android.git
synced 2026-07-25 03:45:21 +00:00
security: ensure media files are deleted during panic mode (#607)
Closes #591 - Added FileUtils.clearAllMedia() to recursively delete media directories and cache. - Called clearAllMedia() in ChatViewModel.panicClearAllData(). fix: correct voice notes directory path for cleanup - Updated FileUtils.clearAllMedia to use 'voicenotes' instead of 'voice_notes' to match VoiceRecorder.kt fix: update media cleanup to include cache directories - Updated FileUtils.clearAllMedia to explicitly clean 'files/incoming' and 'images/incoming' from context.cacheDir, reflecting the storage location change from issue #592. - Maintained legacy cleanup for context.filesDir. Co-authored-by: a1denvalu3 <>
This commit is contained in:
co-authored by
a1denvalu3 <>
parent
5501141ae0
commit
39e43fa923
@@ -926,6 +926,9 @@ class ChatViewModel(
|
||||
|
||||
// Clear all notifications
|
||||
notificationManager.clearAllNotifications()
|
||||
|
||||
// Clear all media files
|
||||
com.bitchat.android.features.file.FileUtils.clearAllMedia(getApplication())
|
||||
|
||||
// Clear Nostr/geohash state, keys, connections, bookmarks, and reinitialize from scratch
|
||||
try {
|
||||
|
||||
Reference in New Issue
Block a user