1
0
Fork 0
mirror of https://github.com/vbatts/git-validation.git synced 2024-12-28 08:16:31 +00:00

Merge pull request #20 from wking/replace-arg-order

main: Fix strings.Replace argument order
This commit is contained in:
Vincent Batts 2017-03-21 18:20:26 -04:00 committed by GitHub
commit cf8d44cfd7

View file

@ -51,7 +51,7 @@ func main() {
if commitRange == "" {
if strings.ToLower(os.Getenv("TRAVIS")) == "true" && !*flNoTravis {
if os.Getenv("TRAVIS_COMMIT_RANGE") != "" {
commitRange = strings.Replace("...", "..", os.Getenv("TRAVIS_COMMIT_RANGE"), 1)
commitRange = strings.Replace(os.Getenv("TRAVIS_COMMIT_RANGE"), "...", "..", 1)
} else if os.Getenv("TRAVIS_COMMIT") != "" {
commitRange = os.Getenv("TRAVIS_COMMIT")
}