Skip to content

Commit 0769324

Browse files
authored
fix: indentation (#29)
1 parent 1d8c41c commit 0769324

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

store-cli.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,12 @@ package main
22

33
import (
44
"fmt"
5+
"log"
56
"net/url"
67
"os"
78
"path/filepath"
89
"runtime/debug"
910
"strings"
10-
"log"
1111

1212
"github.com/screwdriver-cd/store-cli/sdstore"
1313
"github.com/urfave/cli"
@@ -43,14 +43,14 @@ func finalRecover() {
4343
// Skip cache action for PR jobs (event, pipeline scope)
4444
func skipCache(storeType, scope, action string) bool {
4545
// if is not cache, or if job is not PR
46-
if (storeType != "cache" || os.Getenv("SD_PULL_REQUEST") == "") {
46+
if storeType != "cache" || os.Getenv("SD_PULL_REQUEST") == "" {
4747
return false
4848
}
4949

5050
// For PR jobs,
5151
// skip PR event cache to save time, since PR event only consists of 1 job
5252
// skip pipeline scoped unless it's trying to get
53-
if (scope == "event" || (scope == "pipeline" && action != "get")) {
53+
if scope == "event" || (scope == "pipeline" && action != "get") {
5454
log.Printf("Skipping %s %s-scoped cache for Pull Request", action, scope)
5555
return true
5656
}

store-cli_test.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,9 +20,9 @@ func TestSkipCache(t *testing.T) {
2020
testCases := []struct {
2121
storeType string
2222
scope string
23-
action string
24-
prNum string
25-
expected bool
23+
action string
24+
prNum string
25+
expected bool
2626
}{
2727
{"cache", "pipeline", "get", "", false},
2828
{"cache", "pipeline", "get", "123", false},

0 commit comments

Comments
 (0)