Compare commits

...

2 Commits

Author SHA1 Message Date
279db74568 10.0.30 2023-08-23 10:58:38 +02:00
b84c504f11 fix(core): update 2023-08-23 10:58:38 +02:00
3 changed files with 14 additions and 3 deletions

View File

@ -1,7 +1,7 @@
{
"name": "@push.rocks/smartfile",
"private": false,
"version": "10.0.29",
"version": "10.0.30",
"description": "offers smart ways to work with files in nodejs",
"main": "dist_ts/index.js",
"typings": "dist_ts/index.d.ts",

View File

@ -3,6 +3,6 @@
*/
export const commitinfo = {
name: '@push.rocks/smartfile',
version: '10.0.29',
version: '10.0.30',
description: 'offers smart ways to work with files in nodejs'
}

View File

@ -40,7 +40,18 @@ export const fileExists = async (filePath): Promise<boolean> => {
/**
* Checks if given path points to an existing directory
*/
export const isDirectory = (pathArg): boolean => {
export const isDirectory = (pathArg: string): boolean => {
try {
return plugins.fsExtra.statSync(pathArg).isDirectory();
} catch (err) {
return false;
}
};
/**
* Checks if given path points to an existing directory
*/
export const isDirectorySync = (pathArg: string): boolean => {
try {
return plugins.fsExtra.statSync(pathArg).isDirectory();
} catch (err) {