Simplify loop

This commit is contained in:
Christoph (Sheogorath) Kern 2017-12-22 12:19:19 +01:00 committed by GitHub
parent 9949795533
commit fc626a6724
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 8 deletions

View File

@ -95,14 +95,9 @@ config.isLDAPEnable = config.ldap.url
config.isPDFExportEnable = config.allowpdfexport
// generate correct path
config.sslcapath = (function () {
var i, len, results
results = []
for (i = 0, len = config.sslcapath.length; i < len; i++) {
results.push(path.resolve(appRootPath, config.sslcapath[i]))
}
return results
})()
config.sslcapath.forEach(function (capath, i, array) {
array[i] = path.resolve(appRootPath, capath)
})
config.sslcertpath = path.join(appRootPath, config.sslcertpath)
config.sslkeypath = path.join(appRootPath, config.sslkeypath)