Skip to content

Commit

Permalink
jshint "onevar":true
Browse files Browse the repository at this point in the history
  • Loading branch information
rvagg committed Jan 23, 2013
1 parent 9a536e8 commit daf922a
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
1 change: 1 addition & 0 deletions .jshintrc
Expand Up @@ -27,4 +27,5 @@
, "es5": true
, "esnext": true
, "strict": false
, "onevar": true
}
10 changes: 7 additions & 3 deletions lib/levelup.js
Expand Up @@ -368,14 +368,18 @@ LevelUP.prototype.toString = function () {
}

module.exports = function (location, options, callback) {
var message
, error
, levelup

if (typeof options == 'function') {
callback = options
options = {}
}

if (typeof location != 'string') {
var message = 'Must provide a location for the database'
var error = new errors.InitializationError(message)
message = 'Must provide a location for the database'
error = new errors.InitializationError(message)

if (callback) {
return callback(error)
Expand All @@ -384,7 +388,7 @@ module.exports = function (location, options, callback) {
throw error
}

var levelup = new LevelUP(location, options)
levelup = new LevelUP(location, options)
levelup.open(callback)
return levelup
}
Expand Down

0 comments on commit daf922a

Please sign in to comment.