Skip to content
This repository has been archived by the owner on Jul 1, 2021. It is now read-only.

Commit

Permalink
fixed toRelativePath() in helpers
Browse files Browse the repository at this point in the history
  • Loading branch information
mkloubert committed Jun 11, 2017
1 parent 29fc7d7 commit 809ae3d
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Change Log (vs-deploy)

## 9.24.1 (June 11th, 2017; sync when open)
## 9.24.2 (June 11th, 2017; sync when open)

* displaying message in output channel when synching a file when opening it now
* bugfixes
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "vs-deploy",
"displayName": "Deploy",
"description": "Commands for deploying files of your workspace to a destination.",
"version": "9.24.1",
"version": "9.24.2",
"publisher": "mkloubert",
"engines": {
"vscode": "^1.6.0"
Expand Down
4 changes: 2 additions & 2 deletions src/helpers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2424,8 +2424,8 @@ export function toRelativePath(path: string, baseDir?: string): string | false {
try {
let normalizedPath = replaceAllStrings(path, Path.sep, '/');

let wsRootPath = replaceAllStrings(vscode.workspace.rootPath, Path.sep, '/');
if (wsRootPath) {
let wsRootPath = replaceAllStrings(baseDir, Path.sep, '/');
if ('' !== wsRootPath) {
if (FS.existsSync(wsRootPath)) {
if (FS.lstatSync(wsRootPath).isDirectory()) {
if (0 === normalizedPath.indexOf(wsRootPath)) {
Expand Down

0 comments on commit 809ae3d

Please sign in to comment.