Skip to content

Commit 3c91f41

Browse files
author
Lars Moastuen
committed
Improve readability for not-equal VersionInt() check
1 parent d33a96d commit 3c91f41

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

migrate.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ type Migration struct {
8181

8282
func (m Migration) Less(other *Migration) bool {
8383
switch {
84-
case m.isNumeric() && other.isNumeric() && m.VersionInt()-other.VersionInt() != 0:
84+
case m.isNumeric() && other.isNumeric() && m.VersionInt() != other.VersionInt():
8585
return m.VersionInt() < other.VersionInt()
8686
case m.isNumeric() && !other.isNumeric():
8787
return true

0 commit comments

Comments
 (0)