Rallly is an open-source scheduling and collaboration tool designed to make organizing events and meetings easier.
TypeScript i18nextnext-authnextjspostgresqlprismareact-emailt3-stacktailwindcsstrpcturborepotypescriptzod
📈 Automatically set poll group name (#1900)
Luke Vellaf6451b4fec3f
diff --git a/apps/web/src/features/analytics/service.ts b/apps/web/src/features/analytics/service.tsindex 8f10c2c93..891d35285 100644--- a/apps/web/src/features/analytics/service.ts+++ b/apps/web/src/features/analytics/service.ts@@ -34,7 +34,6 @@ export class AnalyticsService {case "poll_create":// Set up initial group properties for new pollsthis.setPoll(event.pollId, {- name: event.properties.title, // The PostHog UI identifies a group using the name propertytitle: event.properties.title,status: "live", // New polls start as liveparticipant_count: 0, // New polls start with 0 participants@@ -102,15 +101,14 @@ export class AnalyticsService {setPoll(pollId: string, properties: Partial<PollGroupProperties>): void {if (!this.posthog) return;- try {- this.posthog.groupIdentify({- groupType: "poll",- groupKey: pollId,- properties,- });- } catch (error) {- console.error("Failed to update poll group:", error);- }+ this.posthog.groupIdentify({+ groupType: "poll",+ groupKey: pollId,+ properties: {+ ...properties,+ name: properties.title,+ },+ });}/**