mirror of
https://github.com/discourse/discourse.git
synced 2024-11-24 09:17:30 +08:00
c0a086a988
This commit changes the ChatThreadsManager into a native class instead of an ember service, and initializes it for every ChatChannel model. This way each channel has its own thread manager and cache that we can load/unload as needed, and we also move activeThread to the channel since it makes more sense to keep it there, not inside the chat service. The pattern of calling setOwner with the passed in owner from ChatChannel is adapted from the latest ember docs, and is needed to avoid the error below when calling services from the native class: > Attempting to lookup an injected property on an object without a container, ensure that the object was instantiated via a container It works well _only_ if we use our own getOwner wrapper from addon/lib/get-owner, which is for backwards compat. c.f. https://guides.emberjs.com/release/in-depth-topics/native-classes-in-depth/ |
||
---|---|---|
.. | ||
app | ||
assets | ||
config | ||
db | ||
lib | ||
public | ||
spec | ||
test/javascripts | ||
plugin.rb | ||
README.md |
This plugin is still in active development and may change frequently
Documentation
The Discourse Chat plugin adds chat functionality to your Discourse so it can natively support both long-form and short-form communication needs of your online community.
For user documentation, see Discourse Chat.
For developer documentation, see Discourse Documentation.