removed extra param unescaping as it was fixed in echo

This commit is contained in:
Gani Georgiev
2023-07-25 12:46:20 +03:00
parent c3f7aeb856
commit b0aa387235
4 changed files with 64 additions and 9 deletions
+1 -3
View File
@@ -4,7 +4,6 @@ import (
"context"
"log"
"net/http"
"net/url"
"path/filepath"
"time"
@@ -132,8 +131,7 @@ func (api *backupApi) restore(c echo.Context) error {
return NewBadRequestError("Try again later - another backup/restore process has already been started.", nil)
}
// @todo remove the extra unescape after https://github.com/labstack/echo/issues/2447
key, _ := url.PathUnescape(c.PathParam("key"))
key := c.PathParam("key")
existsCtx, cancel := context.WithTimeout(context.Background(), 30*time.Second)
defer cancel()