Skip to content
This repository has been archived by the owner on Dec 15, 2022. It is now read-only.

Commit

Permalink
Restore behavior of using segment count for depth
Browse files Browse the repository at this point in the history
  • Loading branch information
kevinsawicki committed Jan 8, 2014
1 parent 9214891 commit 7d5c675
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/filter.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,8 @@ basenameScore = (string, query, score) ->
score += stringScore(base, query)

# Shallow files are scored higher
depth = Math.max(1, 10 - slashCount)
segmentCount = slashCount + 1
depth = Math.max(1, 10 - segmentCount)
score *= depth * 0.01
score

Expand Down

0 comments on commit 7d5c675

Please sign in to comment.