diff options
author | Christoph (Sheogorath) Kern | 2017-12-22 12:19:19 +0100 |
---|---|---|
committer | GitHub | 2017-12-22 12:19:19 +0100 |
commit | fc626a672410d8990eefb748f59d3a5ab5027c2d (patch) | |
tree | 5be40da702bd3f187d4dd9487d5e122b3cfed5ae | |
parent | 9949795533d2a83d7c63367a1297b7b2626d1e7e (diff) |
Simplify loop
Diffstat (limited to '')
-rw-r--r-- | lib/config/index.js | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/lib/config/index.js b/lib/config/index.js index 6ed652ad..eb59db03 100644 --- a/lib/config/index.js +++ b/lib/config/index.js @@ -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) |