message_store: Fix get_cached_message type.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
This commit is contained in:
Anders Kaseorg 2024-05-03 13:54:12 -07:00 committed by Tim Abbott
parent fe6744ae54
commit 7a10d8329b
1 changed files with 1 additions and 1 deletions

View File

@ -149,7 +149,7 @@ export function update_message_cache(message: Message): void {
stored_messages.set(message.id, message); stored_messages.set(message.id, message);
} }
export function get_cached_message(message_id: number): Message { export function get_cached_message(message_id: number): Message | undefined {
// You should only call this from message_helper. // You should only call this from message_helper.
// Use the get() wrapper below for most other use cases. // Use the get() wrapper below for most other use cases.
return stored_messages.get(message_id); return stored_messages.get(message_id);