Skip to content

Commit

Permalink
remove unnecessary check
Browse files Browse the repository at this point in the history
Signed-off-by: AdamKorcz <adam@adalogics.com>
  • Loading branch information
AdamKorcz committed Nov 16, 2023
1 parent 72b59f3 commit 0310029
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions checks/raw/pinned_dependencies.go
Original file line number Diff line number Diff line change
Expand Up @@ -116,12 +116,6 @@ func fileIsInVendorDir(pathfn string) bool {
cleanedPath := filepath.Clean(pathfn)
splitCleanedPath := strings.Split(cleanedPath, "/")

// If the project vendors, this is likely to be how
// they do it. Therefore, check the first index
// before looping.
if splitCleanedPath[0] == "vendor" {
return true
}
for _, d := range splitCleanedPath {
if strings.EqualFold(d, "vendor") {
return true
Expand Down

0 comments on commit 0310029

Please sign in to comment.