fix: infinite loop if new multi-level folder (close #1661)

This commit is contained in:
Noah Hsu
2022-09-13 18:34:04 +08:00
parent 53e08e75fe
commit 2de0da87fa
2 changed files with 10 additions and 1 deletions

View File

@ -8,6 +8,7 @@ import (
"io"
"net/http"
"os"
"time"
"github.com/alist-org/alist/v3/drivers/base"
"github.com/alist-org/alist/v3/internal/driver"
@ -90,6 +91,9 @@ func (d *Quark) MakeDir(ctx context.Context, parentDir model.Obj, dirName string
_, err := d.request("/file", http.MethodPost, func(req *resty.Request) {
req.SetBody(data)
}, nil)
if err == nil {
time.Sleep(time.Second)
}
return err
}