1
0
mirror of https://github.com/KokaKiwi/BarInsta synced 2024-11-22 14:47:29 +00:00

Fix Codacy Issues

This commit is contained in:
junhuicoding 2021-04-01 00:55:20 +08:00
parent f1df75860b
commit 2d2ad6130b

View File

@ -277,8 +277,8 @@ public final class DownloadUtils {
: storyModel.getStoryUrl(); : storyModel.getStoryUrl();
final String baseFileName = storyModel.getStoryMediaId() + "_" final String baseFileName = storyModel.getStoryMediaId() + "_"
+ storyModel.getTimestamp() + DownloadUtils.getFileExtensionFromUrl(url); + storyModel.getTimestamp() + DownloadUtils.getFileExtensionFromUrl(url);
String usernamePrepend = (Utils.settingsHelper.getBoolean(Constants.DOWNLOAD_PREPEND_USER_NAME) final String usernamePrepend = Utils.settingsHelper.getBoolean(Constants.DOWNLOAD_PREPEND_USER_NAME)
&& storyModel.getUsername() != null) ? "@" + storyModel.getUsername() + "_" : ""; && storyModel.getUsername() != null ? "@" + storyModel.getUsername() + "_" : "";
final File saveFile = new File(downloadDir, final File saveFile = new File(downloadDir,
usernamePrepend + baseFileName); usernamePrepend + baseFileName);
download(context, url, saveFile.getAbsolutePath()); download(context, url, saveFile.getAbsolutePath());