Browse Source

corrected wrong merge

Florian DORMONT 11 years ago
parent
commit
12799445f5
1 changed files with 6 additions and 1 deletions
  1. 6 1
      app/OmnomIRC.js

+ 6 - 1
app/OmnomIRC.js

@@ -25,6 +25,7 @@ var fs = require('fs'),
 		}
 		return defaults;
 	})();
+if(typeof fs.existsSync == 'undefined') fs.existsSync = path.existsSync; // legacy support
 if(cluster.isMaster){
 	for(var i=0;i<require('os').cpus().length;i++){
 		cluster.fork();
@@ -265,5 +266,9 @@ if(cluster.isMaster){
 	});
 }
 process.on('uncaughtException',function(e){
-	logger.error(e);
+	if(typeof logger != 'undefined'){
+		logger.error(e);
+	}else{
+		console.error(e);
+	}
 });