mirror of
https://github.com/ClipFusion-org/clipfusion.git
synced 2025-08-03 16:55:08 +00:00
analytics: trying to fix not working analytics
This commit is contained in:
parent
edeff02256
commit
bef758e9fe
@ -3,10 +3,14 @@ import { ReactNode } from "react";
|
||||
// Powered by Umami (https://umami.is/)
|
||||
export default function Analytics(): ReactNode {
|
||||
if (process.env.NODE_ENV == "development") {
|
||||
console.log("Analytics is disabled in development mode");
|
||||
console.log("Analytics is disabled in development environment");
|
||||
return (<></>);
|
||||
}
|
||||
if (process.env.ENABLE_ANALYTICS != "true") {
|
||||
console.log("Analytics is disabled (ENABLE_ANALYTICS=false)");
|
||||
return (<></>);
|
||||
}
|
||||
return (
|
||||
<script defer src={process.env.ANALYTICS_SCRIPT} data-website-id={process.env.ANALYTICS_WEBSITE_ID}/>
|
||||
)
|
||||
);
|
||||
}
|
Loading…
Reference in New Issue
Block a user