Skip to content

Commit

Permalink
Use Discorse API endpoint (#37)
Browse files Browse the repository at this point in the history
* Changed feed api to use monogame community site

* Use the actual discoruse api and not the workaround api endpoint
  • Loading branch information
AristurtleDev authored Nov 22, 2023
1 parent 88d46e4 commit 570af2d
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions scripts/latest-posts.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ async function initialize_community_feeds() {
* it into the #latest-community element on the page
*/
async function get_latest_news() {
let response = await fetch('https://community.monogame.net/latest-news');
let response = await fetch('https://community.monogame.net/latest.json?category=news&order=created');
let json = await response.json();

if (json.topic_list.topics != undefined) {
Expand All @@ -32,7 +32,7 @@ async function get_latest_news() {
* it into the #latest-community element on the page
*/
async function get_latest_community() {
let response = await fetch('https://community.monogame.net/latest-community');
let response = await fetch('https://community.monogame.net/latest.json?order=created');
let json = await response.json();

if (json.topic_list.topics != undefined) {
Expand Down Expand Up @@ -159,4 +159,4 @@ function create_post_block(post) {
return postRoot;
}

initialize_community_feeds();
initialize_community_feeds();

0 comments on commit 570af2d

Please sign in to comment.