mirror of
https://github.com/binwiederhier/ntfy.git
synced 2025-06-18 18:43:15 +02:00
Tiny web app fixes
This commit is contained in:
parent
04b7b4284a
commit
ed0c1abd2f
3 changed files with 8 additions and 5 deletions
web/src/app
|
@ -21,8 +21,11 @@ class Api {
|
|||
const headers = maybeWithAuth({}, user);
|
||||
console.log(`[Api] Polling ${url}`);
|
||||
for await (let line of fetchLinesIterator(url, headers)) {
|
||||
console.log(`[Api, ${shortUrl}] Received message ${line}`);
|
||||
messages.push(JSON.parse(line));
|
||||
const message = JSON.parse(line);
|
||||
if (message.id) {
|
||||
console.log(`[Api, ${shortUrl}] Received message ${line}`);
|
||||
messages.push(message);
|
||||
}
|
||||
}
|
||||
return messages;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue