Update: realpath method in util-path.js

1. DOUBLE_DOT_RE will match `a/b/c//../d` path correctly only if
replace `//` with `/` first
2.  `a///b/c` should be the path `a/b/c`