Skip to content
This repository has been archived by the owner on Jan 11, 2025. It is now read-only.

Commit

Permalink
Change eventSource
Browse files Browse the repository at this point in the history
  • Loading branch information
ronilaukkarinen committed Dec 16, 2023
1 parent eccbcef commit 3a2b0b9
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
### 1.0.1: 2023-12-16
### 1.0.2: 2023-12-16

* Fix error with filtering by language
* Truncate long statuses
Expand Down
9 changes: 7 additions & 2 deletions index.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
// Set version
$version = '1.0.1';
$version = '1.0.2';

// Require composer
require __DIR__ . '/vendor/autoload.php';
Expand Down Expand Up @@ -864,7 +864,12 @@ function customEmojis(str, emojis) {
}

// Set event source
const evtSource = new EventSource("https://corsproxy.io/?https%3A%2F%2Ffedi.buzz%2Fapi%2Fv1%2Fstreaming%2Fpublic");

// Not always reliable
//const evtSource = new EventSource("https://corsproxy.io/?https%3A%2F%2Ffedi.buzz%2Fapi%2Fv1%2Fstreaming%2Fpublic");

// The key is with a temp acc
const evtSource = new EventSource("https://mastodon.social/api/v1/streaming/public?access_token=<?php echo $_ENV['MASTODONSOCIAL_ACCESS_TOKEN']; ?>");

// Main streaming function
function beginStreaming(filter, lang) {
Expand Down

0 comments on commit 3a2b0b9

Please sign in to comment.