Fix API calls from content scripts in Firefox

This fixes the avatars and autorefresh features in Firefox, which didn't
work until now due to the fact that API calls from content scripts
included a |null| value in the |origin| header and this caused the
requests to fail.

Fixed: twpowertools:68
Change-Id: Ia4f5817774d7e38f375a97c3a8c29d524ea4ea90
diff --git a/src/contentScripts/communityConsole/avatars.js b/src/contentScripts/communityConsole/avatars.js
index 41ccd1c..9c555b9 100644
--- a/src/contentScripts/communityConsole/avatars.js
+++ b/src/contentScripts/communityConsole/avatars.js
@@ -156,6 +156,9 @@
             // cache.
             lastMessageId: data?.['1']?.['2']?.['10'],
           };
+        })
+        .catch(cause => {
+          throw new Error('Failed ViewThread request.', {cause});
         });
   }