Removed logging
parent
f611b72234
commit
3390598bb7
|
@ -19,7 +19,6 @@ function PeerList() {
|
||||||
|
|
||||||
// Initial loading
|
// Initial loading
|
||||||
self.getUser = async () => {
|
self.getUser = async () => {
|
||||||
console.log(`Getting user...`)
|
|
||||||
let res; try {
|
let res; try {
|
||||||
res = await fetch(`${API_URL}/`)
|
res = await fetch(`${API_URL}/`)
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
|
@ -35,13 +34,11 @@ function PeerList() {
|
||||||
console.error('Failed to parse JSON!')
|
console.error('Failed to parse JSON!')
|
||||||
if (err) console.error(err)
|
if (err) console.error(err)
|
||||||
}
|
}
|
||||||
console.log(user)
|
|
||||||
self.peers(
|
self.peers(
|
||||||
user.peers.sort(
|
user.peers.sort(
|
||||||
(a,b) => a.ipv4.split('.')[3] - b.ipv4.split('.')[3])
|
(a,b) => a.ipv4.split('.')[3] - b.ipv4.split('.')[3])
|
||||||
.map( (i)=>new Peer(i))
|
.map( (i)=>new Peer(i))
|
||||||
)
|
)
|
||||||
console.log(self.peers())
|
|
||||||
self.token = user.token
|
self.token = user.token
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue