TfTHacker / obsidian42-brat

BRAT - Beta Reviewer's Auto-update Tool for Obsidian.

Home Page:https://tfthacker.com/BRAT

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Console error on missing optional styles.css

codyburleson opened this issue · comments

styles.css is optional in plugins, isn't it? Console is producing error when it's not found...

error in grabReleaseFileFromRepository https://github.com/codyburleson/litmojo/releases/download/0.0.4/styles.css Error: Request failed, status 404
    at new t (app.js:1:699319)
    at Xb (app.js:1:699511)
    at app.js:1:700188
    at app.js:1:235201
    at Object.next (app.js:1:235306)
    at a (app.js:1:234045)

This is not a big deal because it still seems to work, but maybe you want to know anyway?

Thank you for reporting this. In fact this is by design. BRAT is mostly designed for testing. So its alerting the dev that a core file is missing. It is true, Obsidian ignores this if the file is missing, but it still look for it.

I include even and empty styles.css in every release just to show that this component has been thought through.

If its getting annoying though, let me know, we could create a toggle for the feature.

This should be a toggle that is by default disabled. Considering its optional nature, having a hard-coded dependency simply causes false positives to arise when using this plugin. Likewise, it also pollutes the console log with unnecessary error messages.