Error on XHR from content script to local file without any effect

Hello dear community.
When I’m making a XHR request to a file located in my add-on directory from a content script I get the following error message: Security Error: Content from https://www.domain.com/ may not load or link moz-extension://addonid/resources/json/defaults.json (I had to translate it so the error message may not perfectly match) Despite this error I still receive the content of the file.

This error does not occur when using fetch with mode: ‘same-origin’, but without “same-origin” it behaves like XHR.

Btw it doesn’t matter if I declare the file in web_accessible_resources.

Is this intended?
Thanks in advance

1 Like