()
| 48 | * Prepare storage path |
| 49 | */ |
| 50 | export const getStoragePath = (): string => { |
| 51 | const storagePath = process.env.BLOB_STORAGE_PATH |
| 52 | ? path.join(process.env.BLOB_STORAGE_PATH) |
| 53 | : path.join(getUserHome(), '.flowise', 'storage') |
| 54 | if (!fs.existsSync(storagePath)) { |
| 55 | fs.mkdirSync(storagePath, { recursive: true }) |
| 56 | } |
| 57 | return storagePath |
| 58 | } |
| 59 | |
| 60 | /** |
| 61 | * Get the storage type - local or cloud |
no test coverage detected