Await logging response
parent
aece72bd25
commit
caa4777994
|
@ -44,4 +44,4 @@ while IFS= read -r line; do
|
|||
*) printf 'ERROR! Invalid format for %s: %s\n' "${0}" "${format}" >>"${LOGFILE}"
|
||||
exit 5;
|
||||
esac
|
||||
done | sed 's/\n//g' | sed 's/,$//' # Remove trailing comma and newline
|
||||
done | sed 's/\n//g' | sed 's/,$//' # Remove trailing comma and newlines
|
||||
|
|
|
@ -35,7 +35,7 @@ function PeerList() {
|
|||
if (res.status) console.log(res.status)
|
||||
alert('Failed to contact API and load peers list. Check your wireguard connection. ')
|
||||
} else {
|
||||
console.log(res.text())
|
||||
console.log(await res.text())
|
||||
let user; try {
|
||||
user = await res.json()
|
||||
} catch (err) {
|
||||
|
|
Loading…
Reference in New Issue