diff options
author | daniel oeh <daniel.oeh@gmail.com> | 2014-07-07 21:01:37 +0200 |
---|---|---|
committer | daniel oeh <daniel.oeh@gmail.com> | 2014-07-07 21:01:37 +0200 |
commit | 74294bad557e7079dac30b45853cba1271046d6f (patch) | |
tree | b2352746711a3b1237778b6c0c7ea5ecd6a804ee /src/de | |
parent | f59623bb94bd338ddf59e39373f5ab50f9118216 (diff) | |
download | AntennaPod-74294bad557e7079dac30b45853cba1271046d6f.zip |
Remove leading and trailing whitespace in URLChecker. fixes #461
Diffstat (limited to 'src/de')
-rw-r--r-- | src/de/danoeh/antennapod/util/URLChecker.java | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/de/danoeh/antennapod/util/URLChecker.java b/src/de/danoeh/antennapod/util/URLChecker.java index af0226ce0..9997daaf7 100644 --- a/src/de/danoeh/antennapod/util/URLChecker.java +++ b/src/de/danoeh/antennapod/util/URLChecker.java @@ -1,6 +1,9 @@ package de.danoeh.antennapod.util; import android.util.Log; + +import org.apache.commons.lang3.StringUtils; + import de.danoeh.antennapod.BuildConfig; /** @@ -27,6 +30,7 @@ public final class URLChecker { */ public static String prepareURL(String url) { StringBuilder builder = new StringBuilder(); + url = StringUtils.trim(url); if (url.startsWith("feed://")) { if (BuildConfig.DEBUG) Log.d(TAG, "Replacing feed:// with http://"); url = url.replaceFirst("feed://", "http://"); |