Skip to content

Commit

Permalink
Try a fetch directly during bootup too
Browse files Browse the repository at this point in the history
  • Loading branch information
suchmememanyskill committed Mar 10, 2024
1 parent b9e0dbf commit 3506397
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions css_inject.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,8 @@ async def every(__seconds: float, func, *args, **kwargs):
async def initialize_class_mappings():
css_translations_path = os.path.join(get_theme_path(), "css_translations.json")

await fetch_class_mappings(css_translations_path)

asyncio.get_event_loop().create_task(every(60, fetch_class_mappings, css_translations_path))

if not os.path.exists(css_translations_path):
Expand Down

0 comments on commit 3506397

Please sign in to comment.