Skip to content

Commit

Permalink
Fixes lint issues with #647
Browse files Browse the repository at this point in the history
  • Loading branch information
Steve Ramage committed Nov 5, 2021
1 parent b63f099 commit fa52996
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Expand Up @@ -11,7 +11,7 @@
1. Write awesome code ...
1. `make test` to run all tests against all database versions
1. Push code and open Pull Request

:wq
Some more helpful commands:

* You can specify which database/ source tests to run:
Expand Down
6 changes: 3 additions & 3 deletions database/mongodb/mongodb.go
Expand Up @@ -36,7 +36,7 @@ const LockIndexName = "lock_unique_key" // the name of the inde
const contextWaitTimeout = 5 * time.Second // how long to wait for the request to mongo to block/wait for.

var (
ErrNoDatabaseName = fmt.Errorf("no database name")
ErrNoDatabaseName = fmt.Errorf("no database name")
ErrNilConfig = fmt.Errorf("no config")
ErrTypoAndNotNonTypoUsed = fmt.Errorf("both x-advisory-lock-timeout-interval and x-advisory-lock-timout-interval were specified")
)
Expand Down Expand Up @@ -146,9 +146,9 @@ func (m *Mongo) Open(dsn string) (database.Driver, error) {

lockTimeout := lockTimeoutIntervalValue

if (lockTimeoutIntervalValue != "" && lockTimeoutIntervalValueFromTypo != "") {
if lockTimeoutIntervalValue != "" && lockTimeoutIntervalValueFromTypo != "" {
return nil, ErrTypoAndNotNonTypoUsed
} else if (lockTimeoutIntervalValueFromTypo != "") {
} else if lockTimeoutIntervalValueFromTypo != "" {
lockTimeout = lockTimeoutIntervalValueFromTypo
}

Expand Down

0 comments on commit fa52996

Please sign in to comment.