diff --git a/web/src/fetch_status.ts b/web/src/fetch_status.ts index f60f4b4c4e..4ae7298cc7 100644 --- a/web/src/fetch_status.ts +++ b/web/src/fetch_status.ts @@ -141,4 +141,15 @@ export class FetchStatus { max_id_for_messages(messages), ); } + + copy_status(fetch_status: FetchStatus): void { + this._found_newest = fetch_status.has_found_newest(); + this._found_oldest = fetch_status.has_found_oldest(); + this._expected_max_message_id = fetch_status._expected_max_message_id; + this._history_limited = fetch_status._history_limited; + // We don't want to copy over the loading state of the message list + // data since the same data object is not used for two messages lists + // and hence when the fetch is finished, only the original message list + // data will be updated. + } }