From e02a5987d2a31e2462f0b79df9aa736762fea4d5 Mon Sep 17 00:00:00 2001 From: Hans-Christoph Steiner Date: Wed, 8 Aug 2018 14:04:31 +0200 Subject: [PATCH] make DownloaderService use urlString var names like rest of code --- .../fdroid/fdroid/net/DownloaderService.java | 20 ++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/app/src/main/java/org/fdroid/fdroid/net/DownloaderService.java b/app/src/main/java/org/fdroid/fdroid/net/DownloaderService.java index e9d598619..c670baf71 100644 --- a/app/src/main/java/org/fdroid/fdroid/net/DownloaderService.java +++ b/app/src/main/java/org/fdroid/fdroid/net/DownloaderService.java @@ -271,29 +271,31 @@ public class DownloaderService extends Service { /** * Add a URL to the download queue. - *

+ *

* All notifications are sent as an {@link Intent} via local broadcasts to be received by * - * @param context this app's {@link Context} - * @param urlString The URL to add to the download queue + * @param context this app's {@link Context} + * @param mirrorUrlString The URL to add to the download queue + * @param repoId the database ID number representing one repo + * @param urlString the URL used as the unique ID throughout F-Droid * @see #cancel(Context, String) */ - public static void queue(Context context, String urlString, long repoId, String originalUrlString) { - if (TextUtils.isEmpty(urlString)) { + public static void queue(Context context, String mirrorUrlString, long repoId, String urlString) { + if (TextUtils.isEmpty(mirrorUrlString)) { return; } - Utils.debugLog(TAG, "Preparing " + urlString + " to go into the download queue"); + Utils.debugLog(TAG, "Preparing " + mirrorUrlString + " to go into the download queue"); Intent intent = new Intent(context, DownloaderService.class); intent.setAction(ACTION_QUEUE); - intent.setData(Uri.parse(urlString)); + intent.setData(Uri.parse(mirrorUrlString)); intent.putExtra(Downloader.EXTRA_REPO_ID, repoId); - intent.putExtra(Downloader.EXTRA_CANONICAL_URL, originalUrlString); + intent.putExtra(Downloader.EXTRA_CANONICAL_URL, urlString); context.startService(intent); } /** * Remove a URL to the download queue, even if it is currently downloading. - *

+ *

* All notifications are sent as an {@link Intent} via local broadcasts to be received by * * @param context this app's {@link Context}