pusher / django-pusherable

Real time notification when an object view is accessed via Pusher
BSD 3-Clause "New" or "Revised" License
55 stars 7 forks source link

pusherable_subscribe template tag #11

Open cartermyers opened 6 years ago

cartermyers commented 6 years ago

Hi, I'm not sure if this repo is still maintained or not, but there is just an issue I had that was really frustrating trying to work through the examples. The real issue here is the pusherable_script template tag creates a new Pusher object in JS, but it doesn't specify the cluster, only the app key. I had spent a couple of hours trying to figure out at each step what the problem was (and I'm not an expert with the order of events with class based forms and views so I suspected it was something with the trigger function on the backend side). Anyway, explicitly stating the cluster seemed to work for me.

Again, I don't really know the system all that well, but I'll open a PR and let me know if this is a proper solution.