mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2025-09-19 14:47:57 +08:00
avoid util package depends on security package
This commit is contained in:
@@ -12,8 +12,6 @@ import (
|
||||
"net/url"
|
||||
"strings"
|
||||
"time"
|
||||
|
||||
"github.com/chrislusf/seaweedfs/weed/security"
|
||||
)
|
||||
|
||||
var (
|
||||
@@ -97,7 +95,7 @@ func Head(url string) (http.Header, error) {
|
||||
return r.Header, nil
|
||||
}
|
||||
|
||||
func Delete(url string, jwt security.EncodedJwt) error {
|
||||
func Delete(url string, jwt string) error {
|
||||
req, err := http.NewRequest("DELETE", url, nil)
|
||||
if jwt != "" {
|
||||
req.Header.Set("Authorization", "BEARER "+string(jwt))
|
||||
|
Reference in New Issue
Block a user