Skip to content

Commit 4a0b405

Browse files
author
xxx
committed
1.change default download directory
1 parent 34b687a commit 4a0b405

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

Plugins/FileDownloader/Source/FileDownloader/Private/FileDownloadManager.cpp

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -161,13 +161,7 @@ int32 UFileDownloadManager::AddTaskByUrl(const FString& InUrl, const FString& In
161161
FString TmpDir = InDirectory;
162162
if (TmpDir.IsEmpty())
163163
{
164-
//https://www.google.com/
165-
static int32 URLTag = 8;
166-
int32 StartSlash = InUrl.Find(FString("/"), ESearchCase::IgnoreCase, ESearchDir::FromStart, URLTag);
167-
int32 LastSlash = InUrl.Find(FString("/"), ESearchCase::IgnoreCase, ESearchDir::FromEnd);
168-
FString UrlDirectory = InUrl.Mid(StartSlash, LastSlash - StartSlash);
169-
170-
TmpDir = FPaths::ProjectDir() + UrlDirectory;
164+
TmpDir = FPaths::ProjectSavedDir();
171165
}
172166

173167
for (const auto It: TaskList)

0 commit comments

Comments
 (0)