Skip to content

Commit a8bc9ee

Browse files
committed
Fix browser check
1 parent 8de6347 commit a8bc9ee

File tree

5 files changed

+10
-5
lines changed

5 files changed

+10
-5
lines changed

CHANGES.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
# Changelog
22

3+
## v4.2.1
4+
5+
- Fix browser check
6+
37
## 4.2.0
48

59
- Port to TypeScript

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "reverse-image-search",
33
"description": "Reverse Image Search",
4-
"version": "4.2.0",
4+
"version": "4.2.1",
55
"author": "Brawl345",
66
"license": "Unlicense",
77
"repository": {

public/manifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"name": "__MSG_extensionName__",
55
"description": "__MSG_extensionDescription__",
66
"author": "Andreas Bielawski",
7-
"version": "4.2.0",
7+
"version": "4.2.1",
88
"icons": {
99
"16": "icons/16.png",
1010
"32": "icons/32.png",

source/options/components/Provider.svelte

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
$: iconUrl = getIcon(provider.icon);
2424
2525
const uploadIcon = () => {
26-
if (isFirefox) {
26+
if (!isFirefox) {
2727
errorMsg = getMessage("msgIconUploadNotSupported");
2828
return;
2929
}

source/utils.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,5 +50,6 @@ export const base64EncodeIcon = (ctx: CanvasRenderingContext2D): string => {
5050
return jpegBase64;
5151
};
5252

53-
// @ts-ignore
54-
export const isFirefox = window.browser && browser.runtime;
53+
export const isFirefox =
54+
// @ts-ignore
55+
typeof window !== 'undefined' && window.browser && browser.runtime;

0 commit comments

Comments
 (0)