Skip to content

Commit

Permalink
Unrelated fixes to pass the CI
Browse files Browse the repository at this point in the history
  • Loading branch information
glpatcern committed Feb 2, 2024
1 parent 31218c1 commit 064c4a5
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
2 changes: 1 addition & 1 deletion internal/grpc/interceptors/auth/scope.go
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ func expandAndVerifyScope(ctx context.Context, req interface{}, tokenScope map[s
}
}
} else {
log.Trace().Msgf("Token scope is not ok. req:%+v, tokenScope:%+v", req, tokenScope, req, tokenScope)
log.Trace().Msgf("Token scope is not ok. req:%+v, tokenScope:%+v", req, tokenScope)
}

if checkLightweightScope(ctx, req, tokenScope, client) {
Expand Down
9 changes: 4 additions & 5 deletions pkg/eosclient/eosbinary/eosbinary.go
Original file line number Diff line number Diff line change
Expand Up @@ -929,7 +929,6 @@ func parseRecycleEntry(raw string) (*eosclient.DeletedEntry, error) {
IsDir: isDir,
}


// rewrite the restore-path to take into account the key keylength.restore-path
keyLengthString, ok := kv["keylength.restore-path"]
if !ok {
Expand All @@ -942,9 +941,9 @@ func parseRecycleEntry(raw string) (*eosclient.DeletedEntry, error) {
}

// find the index of the restore-path key string in the raw string
// ... restore-path=/eos/scratch/user/g/gonzalhu/app.ico ....
// NOTE: this code will break if another key of the output will contain the string "restore-path=/" in it (very unlikely)
index:= strings.Index(raw, "restore-path=/")
// ... restore-path=/eos/scratch/user/g/gonzalhu/app.ico ....
// NOTE: this code will break if another key of the output will contain the string "restore-path=/" in it (very unlikely)
index := strings.Index(raw, "restore-path=/")
if index == -1 {
return nil, errors.New(fmt.Sprintf("restore-path key not found in raw string: %s", raw))
}
Expand Down Expand Up @@ -1206,7 +1205,7 @@ func (c *Client) mapToFileInfo(ctx context.Context, kv, attrs map[string]string,
if !mtimeSet {
mtimeSplit := strings.Split(kv["mtime"], ".")
mtimesec, _ = strconv.ParseUint(mtimeSplit[0], 10, 64)
mtimenanos, _= strconv.ParseUint(mtimeSplit[1], 10, 32)
mtimenanos, _ = strconv.ParseUint(mtimeSplit[1], 10, 32)
}

var ctimesec, ctimenanos uint64
Expand Down

0 comments on commit 064c4a5

Please sign in to comment.