Changed how account data is stored, authorization header is now sent when logged in, adjusted spacing game filters for server list, fixed crashing when trying to load icon for game whos icon is not present, a bit of code cleanup to Api to use Async::HTTP::Client over Async::Internet directly (for everything except get requests), probably a few misc. changes

This commit is contained in:
2022-02-04 08:59:15 -06:00
parent 4996315aeb
commit 7da254fd61
11 changed files with 114 additions and 74 deletions

View File

@@ -63,18 +63,18 @@ class W3DHub
Async do
internet = Async::HTTP::Internet.instance
fetch_w3dhub_news(internet)
fetch_w3dhub_news
populate_w3dhub_news
end
end
end
def fetch_w3dhub_news(internet)
news = Api.news(internet, "launcher-home")
def fetch_w3dhub_news
news = Api.news("launcher-home")
if news
news.items[0..9].each do |item|
Cache.fetch(internet, item.image)
Cache.fetch(item.image)
end
@w3dhub_news = news