dubinc / dub

Open-source link management infrastructure. Loved by modern marketing teams like Twilio, Perplexity, Vercel, and Huberman Labs.

Home Page:https://dub.co

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

CSV download option visible to non-business users on Events page, causing unclear error

unrenamed opened this issue · comments

Issue Summary

On the Events page, users with a billing plan lower than Business can see the option to download a CSV of the Real-time Events Stream, but clicking it results in a vague "Error" toast message. This error message does not explain the root cause, and ideally, the CSV download option should be hidden for users on plans below Business since the feature is not accessible to them.

Steps to Reproduce

  1. Log in with an account on a billing plan below Business.
  2. Navigate to the Events page.
  3. Attempt to download a CSV of the Real-time Events Stream by clicking the download option.
  4. Observe the "Error" toast message that appears without further explanation.

Expected Behavior

For users on plans below Business, the CSV download option ideally should be hidden, preventing access to features not included in their subscription.

Alternative approaches

If the option remains visible, a clear error message should appear, explaining that CSV downloads are available only for Business plans.

Reproduction Video

Screen.Recording.2024-10-25.at.20.26.36.mov

great catch! Lets go ahead and disable the download csv button (not the dropdown) when plan === 'free' or plan === 'pro'

/award 150

Awarding unrenamed: 150 points 🕹️ Well done! Check out your new contribution on oss.gg/unrenamed