We have implemented Passport where any user can subscribe to this passport. I want to restrict subscriptions after 20 subscriptions happen. How can we go with this.
Any ideas ?
You could use something like Pundit to count the number of subscriptions and cause something else to happen or prevent it from working at that point. Check out this episode https://gorails.com/episodes/authorization-with-pundit
Join 27,623+ developers who get early access to new screencasts, articles, guides, updates, and more.