mirror of
https://github.com/fazo96/ipfs-boards
synced 2025-01-26 15:04:19 +01:00
use gateway api by default
This commit is contained in:
parent
aecf89339c
commit
34da7fcc07
@ -7,7 +7,9 @@ module.exports = {
|
|||||||
} catch (e) {
|
} catch (e) {
|
||||||
// Do nothing
|
// Do nothing
|
||||||
}
|
}
|
||||||
if (opt === null || opt === undefined) opt = { addr: 'localhost', port: 5001 }
|
if (opt === null || opt === undefined) {
|
||||||
|
opt = { addr: window.location.hostname, port: window.location.port }
|
||||||
|
}
|
||||||
return opt
|
return opt
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -4,7 +4,7 @@ var Icon = require('icon.jsx')
|
|||||||
module.exports = function (boardsAPI) {
|
module.exports = function (boardsAPI) {
|
||||||
return React.createClass({
|
return React.createClass({
|
||||||
getDefaults: function () {
|
getDefaults: function () {
|
||||||
return { addr: 'localhost', port: 5001, api: false }
|
return { addr: window.location.hostname, port: window.location.port, api: false }
|
||||||
},
|
},
|
||||||
getInitialState: function () {
|
getInitialState: function () {
|
||||||
var s = window.localStorage.getItem('ipfs-boards-settings')
|
var s = window.localStorage.getItem('ipfs-boards-settings')
|
||||||
|
Loading…
Reference in New Issue
Block a user