Skip to content

Commit

Permalink
Always use forward slash when splitting target names (#612)
Browse files Browse the repository at this point in the history
Signed-off-by: Fredrik Skogman <[email protected]>
  • Loading branch information
kommendorkapten authored Feb 23, 2024
1 parent 454b121 commit 1e7978e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion examples/multirepo/client/client_example.go
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,8 @@ func BootstrapTUF() ([]byte, map[string][]byte, error) {
if name == "map.json" {
mapBytes = bytes
} else {
repositoryName := strings.Split(name, string(os.PathSeparator))
// Target names uses forwardslash even on Windows
repositoryName := strings.Split(name, "/")
trustedRoots[repositoryName[0]] = bytes
}
log.Info("Successfully downloaded target", "target", name, "path", path)
Expand Down

0 comments on commit 1e7978e

Please sign in to comment.