mirror of
https://github.com/skidoodle/hostinfo
synced 2026-04-28 09:37:37 +02:00
Bug fixes and performance improvements
This commit is contained in:
@@ -1,10 +1,8 @@
|
||||
import { browser } from 'wxt/browser';
|
||||
|
||||
export const Header = ({ title, flagCode }: { title: string, flagCode?: string | null }) => {
|
||||
const getFlagUrl = (code?: string | null) => {
|
||||
if (!code) return '';
|
||||
try {
|
||||
const path = `/${code.toLowerCase()}.webp`;
|
||||
const path = `/${code.toLowerCase()}.png`;
|
||||
return browser.runtime.getURL(path as any);
|
||||
} catch {
|
||||
return '';
|
||||
|
||||
Reference in New Issue
Block a user