Use filpath.Join()

This commit is contained in:
Xpl0itU 2023-08-03 15:12:28 +02:00
parent ef35f366e5
commit d056005725
3 changed files with 5 additions and 4 deletions

View file

@ -24,7 +24,7 @@ func main() {
}
bundlePath := filepath.Join(filepath.Dir(filepath.Dir(execPath)))
filePath := filepath.Join(bundlePath, "Resources/lib/share/glib-schemas")
filePath := filepath.Join(bundlePath, "Resources", "lib", "share", "glib-schemas")
if _, err := os.Stat(filePath); os.IsNotExist(err) {
logger.Warning("glib-schemas not found")
} else {

View file

@ -764,7 +764,7 @@ queueProcessingLoop:
defer wg.Done()
tidStr := fmt.Sprintf("%016x", title.TitleID)
titlePath := fmt.Sprintf("%s/%s [%s] [%s]", selectedPath, normalizeFilename(title.Name), wiiudownloader.GetFormattedKind(title.TitleID), tidStr)
titlePath := filepath.Join(selectedPath, fmt.Sprintf("%s [%s] [%s]", normalizeFilename(title.Name), wiiudownloader.GetFormattedKind(title.TitleID), tidStr))
if err := wiiudownloader.DownloadTitle(tidStr, titlePath, mw.decryptContents, progressWindow, mw.getDeleteEncryptedContents(), mw.logger); err != nil {
errorChan <- err
return