Skip to content

Commit

Permalink
repository_simulator_setup.go: Use filepath.Join() instead of concate…
Browse files Browse the repository at this point in the history
…nation (#624)

Update repository_simulator_setup.go

Use filepath.Join() instead of concatenation

Signed-off-by: udf2457 <[email protected]>
  • Loading branch information
udf2457 authored Mar 8, 2024
1 parent c893deb commit dfa2ae1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions internal/testutils/simulator/repository_simulator_setup.go
Original file line number Diff line number Diff line change
Expand Up @@ -48,11 +48,11 @@ func InitLocalEnv() error {
os.Exit(1)
}

if err = os.Mkdir(tmpDir+metadataPath, 0750); err != nil {
if err = os.Mkdir(filepath.Join(tmpDir,metadataPath), 0750); err != nil {
slog.Error("Repository simulator: failed to create dir", "err", err)
}

if err = os.Mkdir(tmpDir+targetsPath, 0750); err != nil {
if err = os.Mkdir(filepath.Join(tmpDir,targetsPath), 0750); err != nil {
slog.Error("Repository simulator: failed to create dir", "err", err)
}

Expand Down

0 comments on commit dfa2ae1

Please sign in to comment.