@illgrenoble/node-fs-api
Advanced tools
Comparing version 0.9.3 to 0.9.4
@@ -154,6 +154,8 @@ "use strict"; | ||
fileStats = _a.sent(); | ||
if (file === '..') { | ||
fileStats.path = "".concat(fileStats.path.split('/').slice(0, -2).join('/')); | ||
if (fileStats != null) { | ||
if (file === '..') { | ||
fileStats.path = "".concat(fileStats.path.split('/').slice(0, -2).join('/')); | ||
} | ||
contents.push(fileStats); | ||
} | ||
contents.push(fileStats); | ||
_a.label = 5; | ||
@@ -391,2 +393,5 @@ case 5: | ||
case 0: | ||
if (!path.endsWith('/')) { | ||
path = "".concat(path, "/"); | ||
} | ||
fullPath = "".concat(process.env.HOME).concat(path); | ||
@@ -406,4 +411,4 @@ return [4 /*yield*/, getStats(path)]; | ||
folderName = folderNameIndex === 0 ? folderNamePrefix : "".concat(folderNamePrefix, " ").concat(folderNameIndex); | ||
folderPath = "".concat(path, "/").concat(folderName); | ||
fullFolderPath = "".concat(fullPath, "/").concat(folderName); | ||
folderPath = "".concat(path).concat(folderName); | ||
fullFolderPath = "".concat(fullPath).concat(folderName); | ||
folderExists = exists(folderPath); | ||
@@ -435,2 +440,5 @@ folderNameIndex++; | ||
case 0: | ||
if (!path.endsWith('/')) { | ||
path = "".concat(path, "/"); | ||
} | ||
fullPath = "".concat(process.env.HOME).concat(path); | ||
@@ -450,4 +458,4 @@ return [4 /*yield*/, getStats(path)]; | ||
fileName = fileNameIndex === 0 ? "".concat(fileNamePrefix, ".txt") : "".concat(fileNamePrefix).concat(fileNameIndex, ".txt"); | ||
filePath = "".concat(path, "/").concat(fileName); | ||
fullFilePath = "".concat(fullPath, "/").concat(fileName); | ||
filePath = "".concat(path).concat(fileName); | ||
fullFilePath = "".concat(fullPath).concat(fileName); | ||
fileExists = exists(filePath); | ||
@@ -454,0 +462,0 @@ fileNameIndex++; |
{ | ||
"name": "@illgrenoble/node-fs-api", | ||
"version": "0.9.3", | ||
"version": "0.9.4", | ||
"description": "Provides a REST API to access the file system", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
Sorry, the diff of this file is not supported yet
114546
1135