You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
16 lines
289 B
16 lines
289 B
9 years ago
|
var utils = require('../utils')
|
||
|
, path = require('path');
|
||
|
|
||
|
/**
|
||
|
* Return the dirname of `path`.
|
||
|
*
|
||
|
* @param {String} path
|
||
|
* @return {String}
|
||
|
* @api public
|
||
|
*/
|
||
|
|
||
|
module.exports = function dirname(p){
|
||
|
utils.assertString(p, 'path');
|
||
|
return path.dirname(p.val).replace(/\\/g, '/');
|
||
|
};
|