(href)
| 653 | return "file://" + path; |
| 654 | } |
| 655 | urlToDirectoryPath(href) { |
| 656 | const url = new URL(href); |
| 657 | if (url.protocol == "file:") { |
| 658 | let path = url.pathname; |
| 659 | if (this.windows) |
| 660 | path = path.slice(1).replaceAll('/', '\\'); |
| 661 | if (this.isDirectoryOrFile(path) == -1) |
| 662 | return path; |
| 663 | } |
| 664 | } |
| 665 | urlToFilePath(href) { |
| 666 | const url = new URL(href); |
| 667 | if (url.protocol == "file:") { |
no test coverage detected