fixed bug: nodester do not have env varible HOME

This commit is contained in:
coderaiser 2012-07-14 12:40:00 -04:00
parent 82c7c0a04d
commit 54a1989a6d

View file

@ -167,8 +167,9 @@ CloudServer.start=function()
CloudServer.IP;
/* if Cloud Server started on jitsu */
if(!process.env.HOME.indexOf('/opt/haibu')){
this.IP = '0.0.0.0';
if(process.env.HOME &&
!process.env.HOME.indexOf('/opt/haibu')){
this.IP = '0.0.0.0';
}
/* server mode or testing mode */
if(!process.argv[2] && this.Config.server){