Constructor confugration options
This changes the function signature of the constructor but allows us to pass any options. Mainly this is now used for the ipfs configs.
This commit is contained in:
@@ -5,7 +5,7 @@ class IPFS {
|
||||
|
||||
constructor(config) {
|
||||
if (!config) {
|
||||
config = {host: 'localhost', port: '5001', protocol: 'http'};
|
||||
config = { host: 'localhost', port: '5001', protocol: 'http' };
|
||||
}
|
||||
this._ipfsAPI = ipfsAPI(config);
|
||||
this._config = config;
|
||||
|
||||
Reference in New Issue
Block a user