mirror of
https://github.com/discourse/discourse.git
synced 2025-02-12 14:24:54 +00:00
This commit regroups 3 changes - serializes channel ID and json draft when calling the debouncer instead of inside the debounced function, it seems very unlikely to happen, but in a case where the debouncing wouldn't be canceled and the new message not set yet, we could save the draft on an invalid channel - cancel persist draft handler when changing channel - ensures we exit early when channel is not set