Skip to content

Commit

Permalink
just rely on path.join to insert the correct sep
Browse files Browse the repository at this point in the history
NodeJS 0.6 doesn't support path.sep as that was introduced in Node 0.7,
so let's not use that.  Instead, just rely on path.join to do the right
thing as that's what it's there for.
  • Loading branch information
avalade committed Sep 25, 2012
1 parent c8ed84d commit 0e10ca5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tasks/coffee.js
Expand Up @@ -44,7 +44,7 @@ module.exports = function(grunt) {
extension = typeof extension === "undefined" ? '.js' : extension;

if( destPath && options.preserve_dirs ){
var dirname = path.normalize(path.dirname(src)) + path.sep;
var dirname = path.normalize(path.dirname(src));
if ( options.base_path ) {
//on Windows, path.sep must be escaped in a regex
var safeRegex = path.normalize(options.base_path).replace(/\\/g, "\\\\");
Expand Down

0 comments on commit 0e10ca5

Please sign in to comment.