Standard JS code conversion + fixes

This commit is contained in:
NGPixel
2017-02-08 20:52:37 -05:00
parent a508b2a7f4
commit 414dc386d6
54 changed files with 4022 additions and 4288 deletions

View File

@@ -1,11 +1,9 @@
function makeSafePath(rawPath) {
function makeSafePath (rawPath) {
let rawParts = _.split(_.trim(rawPath), '/')
rawParts = _.map(rawParts, (r) => {
return _.kebabCase(_.deburr(_.trim(r)))
})
let rawParts = _.split(_.trim(rawPath), '/');
rawParts = _.map(rawParts, (r) => {
return _.kebabCase(_.deburr(_.trim(r)));
});
return _.join(_.filter(rawParts, (r) => { return !_.isEmpty(r); }), '/');
}
return _.join(_.filter(rawParts, (r) => { return !_.isEmpty(r) }), '/')
}