Skip to content

Commit

Permalink
git: Fix Status.IsClean() documentation
Browse files Browse the repository at this point in the history
The documentation of the IsClean Method contained a negation, so it was
describing the opposite of its actual behavior.

Fixes src-d#838

Signed-off-by: David Url <david@urld.io>
  • Loading branch information
urld committed Oct 6, 2018
1 parent d3cec13 commit da56abd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion status.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ func (s Status) IsUntracked(path string) bool {
return ok && stat.Worktree == Untracked
}

// IsClean returns true if all the files aren't in Unmodified status.
// IsClean returns true if all the files are in Unmodified status.
func (s Status) IsClean() bool {
for _, status := range s {
if status.Worktree != Unmodified || status.Staging != Unmodified {
Expand Down

0 comments on commit da56abd

Please sign in to comment.