Fix cleaning up APKs on debug builds (#1373)

## Description
Directly use "Wholphin" when searching for older APKs to clean up.

On debug builds, the `app_name` string is "Wholphin (Debug)" but the APK
file names is always "Wholphin.apk", so I think the debug build won't
clean them up.

### Related issues
Fixes #1368

### Testing
Testing downloading a few times without this change, applied the change,
and clean up worked

## Screenshots
N/A

## AI or LLM usage
None
This commit is contained in:
Damontecres 2026-05-11 11:12:05 -04:00 committed by GitHub
parent 9ddce95e57
commit 4928c1156d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -340,7 +340,7 @@ class UpdateChecker
context.contentResolver.delete( context.contentResolver.delete(
MediaStore.Downloads.EXTERNAL_CONTENT_URI, MediaStore.Downloads.EXTERNAL_CONTENT_URI,
"${MediaStore.MediaColumns.DISPLAY_NAME} LIKE ? AND ${MediaStore.MediaColumns.MIME_TYPE} = ?", "${MediaStore.MediaColumns.DISPLAY_NAME} LIKE ? AND ${MediaStore.MediaColumns.MIME_TYPE} = ?",
arrayOf(context.getString(R.string.app_name) + "%", APK_MIME_TYPE), arrayOf("$ASSET_NAME%", APK_MIME_TYPE),
) )
Timber.i("Deleted $deletedRows rows") Timber.i("Deleted $deletedRows rows")
} else { } else {