https request fix path separator

This commit is contained in:
= 2024-11-26 15:49:44 -07:00
parent 4a35078f90
commit dadf5f641b

View File

@ -4,6 +4,7 @@ import (
"context"
"io"
"net/http"
"strings"
"github.com/wailsapp/wails/v2/pkg/runtime"
)
@ -11,6 +12,7 @@ import (
const BlockSize = 1024 * 64
func HttpDownload(path string, out io.Writer, ctx context.Context) error {
path = strings.ReplaceAll(path, "\\", "/")
res, err := http.Get("https://fclauncher.piwalker.net/fclauncher/" + path)
if err != nil {
return err