mirror of
https://github.com/hzrd149/nostrudel.git
synced 2025-09-26 03:28:38 +02:00
only register handler for prod builds
This commit is contained in:
@@ -4,11 +4,13 @@ import { App } from "./app";
|
|||||||
import { Providers } from "./providers";
|
import { Providers } from "./providers";
|
||||||
|
|
||||||
// register nostr: protocol handler
|
// register nostr: protocol handler
|
||||||
try {
|
if (import.meta.env.PROD) {
|
||||||
navigator.registerProtocolHandler("web+nostr", new URL("/l/%s", location.origin).toString());
|
try {
|
||||||
} catch (e) {
|
navigator.registerProtocolHandler("web+nostr", new URL("/l/%s", location.origin).toString());
|
||||||
console.log("Failed to register handler");
|
} catch (e) {
|
||||||
console.log(e);
|
console.log("Failed to register handler");
|
||||||
|
console.log(e);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
const element = document.getElementById("root");
|
const element = document.getElementById("root");
|
||||||
|
Reference in New Issue
Block a user