Skip to content
Myr

removed old path utils

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Tj Holowaychuk · committed by Tj Holowaychuk · parent 6722716 · Browse files · 2 files+4 added−62 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

2 files+4 added−62 removed

  • other:+4 added−62 removed

2 files+4 added−62 removed

modified:lib/view/view.js+4 added-4 removed
modified:lib/utils.js-58 removed
4 unmodified lines
5 * MIT Licensed6 */78/**9 * Module dependencies.10 */1112var path = require('path')13 , basename = path.basename14 , dirname = path.dirname15 , extname = path.extname;1617/**18 * Memory cache.19 */2021var cache = {22 basename: {}23 , dirname: {}24 , extname: {}25};2627/**28 * Cached basename.29 *30 * @param {String} path31 * @return {String}32 * @api private33 */3435exports.basename = function(path){36 return cache.basename[path]37 || (cache.basename[path] = basename(path));38};3940/**41 * Cached dirname.42 *43 * @param {String} path44 * @return {String}45 * @api private46 */4748exports.dirname = function(path){49 return cache.dirname[path]50 || (cache.dirname[path] = dirname(path));51};5253/**54 * Cached extname.55 *56 * @param {String} path57 * @return {String}58 * @api private59 */6061exports.extname = function(path){62 return cache.extname[path]63 || (cache.extname[path] = extname(path));64};6566/**9 * Merge object `b` with `a` giving precedence to10 * values in object `a`.11 *12 * @param {Object} a
110 unmodified lines