Skip to content

Commit a74bddf

Browse files
LinusUjacobheun
authored andcommitted
style: prefer const over let
Prefer const over let when the binding is static, in order to comply with an upcoming Standard rule.
1 parent 3611043 commit a74bddf

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

src/config.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ module.exports = (store) => {
4141
if (key !== undefined && !_has(config, key)) {
4242
return callback(new Error('Key ' + key + ' does not exist in config'))
4343
}
44-
let value = key !== undefined ? _get(config, key) : config
44+
const value = key !== undefined ? _get(config, key) : config
4545
callback(null, value)
4646
})
4747
},

test/node.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ describe('IPFS Repo Tests onNode.js', () => {
2222
return callback(new Error('already locked'))
2323
}
2424

25-
let lockPath = path.join(dir, customLock.lockName)
25+
const lockPath = path.join(dir, customLock.lockName)
2626
fs.writeFileSync(lockPath, '')
2727

2828
callback(null, {

0 commit comments

Comments
 (0)