Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
John McEleney
/
casperjs
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
Commit
45affec1
...
45affec1798ebfba5a6c6afb700a1ab7feb003fd
authored
2013-02-24 23:22:25 +0100
by
Nicolas Perriault
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
fixed fs.dirname()
when dirname(path) === path, now it returns '.'
1 parent
1456d23e
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
1 deletions
bin/bootstrap.js
bin/bootstrap.js
View file @
45affec
...
...
@@ -108,7 +108,8 @@ CasperError.prototype = Object.getPrototypeOf(new Error());
}
if
(
!
fs
.
hasOwnProperty
(
'dirname'
))
{
fs
.
dirname
=
function
dirname
(
path
)
{
return
path
.
replace
(
/
\\
/g
,
'/'
).
replace
(
/
\/[^\/]
*$/
,
''
);
var
dir
=
path
.
replace
(
/
\\
/g
,
'/'
).
replace
(
/
\/[^\/]
*$/
,
''
);
return
dir
===
path
?
'.'
:
dir
;
};
}
if
(
!
fs
.
hasOwnProperty
(
'isWindows'
))
{
...
...
Please
register
or
sign in
to post a comment