Fix pubsub error handling
This commit is contained in:
parent
7a8210cea8
commit
175ec1ba0d
@ -130,7 +130,7 @@ class OrbitDB {
|
||||
logger.warn("Couldn't connect to Pubsub: " + e.message);
|
||||
if(!allowOffline) {
|
||||
logger.debug("'allowOffline' set to false, terminating");
|
||||
this._pubsub.disconnect();
|
||||
if(this._pubsub) this._pubsub.disconnect();
|
||||
throw e;
|
||||
}
|
||||
this.user = { username: username, id: username } // TODO: user id from ipfs hash
|
||||
|
Loading…
x
Reference in New Issue
Block a user