aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/helpers/logger.ts
diff options
context:
space:
mode:
authorRigel Kent <sendmemail@rigelk.eu>2018-08-27 13:28:49 +0200
committerChocobozzz <me@florianbigard.com>2018-08-27 16:03:57 +0200
commitc9d5c64f98c1f1fe7950de60c58edeaf3ace070d (patch)
tree26d828e560054cf8a64628823d3dd86172d44f52 /server/helpers/logger.ts
parent0ee027347ae09ea397e9b85702707e9179537ebd (diff)
downloadPeerTube-c9d5c64f98c1f1fe7950de60c58edeaf3ace070d.tar.gz
PeerTube-c9d5c64f98c1f1fe7950de60c58edeaf3ace070d.tar.zst
PeerTube-c9d5c64f98c1f1fe7950de60c58edeaf3ace070d.zip
replace fs by fs-extra to prevent EMFILE error
Diffstat (limited to 'server/helpers/logger.ts')
-rw-r--r--server/helpers/logger.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/server/helpers/logger.ts b/server/helpers/logger.ts
index 480c5b49e..ce6e38f15 100644
--- a/server/helpers/logger.ts
+++ b/server/helpers/logger.ts
@@ -1,5 +1,5 @@
1// Thanks http://tostring.it/2014/06/23/advanced-logging-with-nodejs/ 1// Thanks http://tostring.it/2014/06/23/advanced-logging-with-nodejs/
2import * as mkdirp from 'mkdirp' 2import { mkdirpSync } from 'fs-extra'
3import * as path from 'path' 3import * as path from 'path'
4import * as winston from 'winston' 4import * as winston from 'winston'
5import { CONFIG } from '../initializers' 5import { CONFIG } from '../initializers'
@@ -7,7 +7,7 @@ import { CONFIG } from '../initializers'
7const label = CONFIG.WEBSERVER.HOSTNAME + ':' + CONFIG.WEBSERVER.PORT 7const label = CONFIG.WEBSERVER.HOSTNAME + ':' + CONFIG.WEBSERVER.PORT
8 8
9// Create the directory if it does not exist 9// Create the directory if it does not exist
10mkdirp.sync(CONFIG.STORAGE.LOG_DIR) 10mkdirpSync(CONFIG.STORAGE.LOG_DIR)
11 11
12function loggerReplacer (key: string, value: any) { 12function loggerReplacer (key: string, value: any) {
13 if (value instanceof Error) { 13 if (value instanceof Error) {