From c77fd588e9c6874b1e8eb4f3130b234fc3cbea63 Mon Sep 17 00:00:00 2001 From: Eric Bailey Date: Mon, 28 Aug 2023 13:55:56 -0500 Subject: [PATCH] wrap mutation in runInAction (#1305) --- src/view/com/post-thread/PostThread.tsx | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/view/com/post-thread/PostThread.tsx b/src/view/com/post-thread/PostThread.tsx index e3dd2cf1..3e951dbf 100644 --- a/src/view/com/post-thread/PostThread.tsx +++ b/src/view/com/post-thread/PostThread.tsx @@ -1,4 +1,5 @@ import React, {useRef} from 'react' +import {runInAction} from 'mobx' import {observer} from 'mobx-react-lite' import { ActivityIndicator, @@ -361,7 +362,9 @@ function* flattenThread( } } } else if (!isAscending && !post.parent && post.post.replyCount) { - post._hasMore = true + runInAction(() => { + post._hasMore = true + }) } }