Open source Loom alternative. Beautiful, shareable screen recordings.
Rust appcapcossloommacnextjsnextjs15open-sourceossreactrecordrustscreen-capturescreen-recorderscreenshotsolidjstauritauri-apptypescriptvite
Improve Tinybird service initialization checks
Richie McIlroyda229de5c99d
diff --git a/packages/web-backend/src/Tinybird/index.ts b/packages/web-backend/src/Tinybird/index.tsindex 67ddc8afc..39dd7a6ac 100644--- a/packages/web-backend/src/Tinybird/index.ts+++ b/packages/web-backend/src/Tinybird/index.ts@@ -31,20 +31,17 @@ export class Tinybird extends Effect.Service<Tinybird>()("Tinybird", {const token = env.TINYBIRD_TOKEN;const host = env.TINYBIRD_HOST;- if (!host) {- yield* Effect.die(new Error("TINYBIRD_HOST must be set"));- }+ const enabled = Boolean(token && host);yield* Effect.logDebug("Initializing Tinybird service", {hasToken: Boolean(token),- host,+ hasHost: Boolean(host),+ enabled,});- const enabled = Boolean(token);-if (!enabled) {yield* Effect.logWarning(- "Tinybird is disabled: TINYBIRD_TOKEN is not set",+ "Tinybird is disabled: TINYBIRD_TOKEN and/or TINYBIRD_HOST not set",);}