mirror of
https://github.com/zulip/zulip.git
synced 2025-11-02 13:03:29 +00:00
actions: Split out zerver.actions.message_send.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
This commit is contained in:
@@ -71,12 +71,12 @@ This section details the ways in which it is different:
|
||||
`apply_markdown` and `client_gravatar` features in our
|
||||
[events API docs](https://zulip.com/api/register-queue)).
|
||||
- Following our standard naming convention, input validation is done
|
||||
inside the `check_message` function in `zerver/lib/actions.py`, which is responsible for
|
||||
inside the `check_message` function in `zerver/actions/message_send.py`, which is responsible for
|
||||
validating the user can send to the recipient,
|
||||
[rendering the Markdown](markdown.md), etc. --
|
||||
basically everything that can fail due to bad user input.
|
||||
- The core `do_send_messages` function (which handles actually sending
|
||||
the message) in `zerver/lib/actions.py` is one of the most optimized and thus complex parts of
|
||||
the message) in `zerver/actions/message_send.py` is one of the most optimized and thus complex parts of
|
||||
the system. But in short, its job is to atomically do a few key
|
||||
things:
|
||||
- Store a `Message` row in the database.
|
||||
|
||||
Reference in New Issue
Block a user