diff options
author | Vitaly Takmazov | 2019-04-16 14:49:28 +0300 |
---|---|---|
committer | Vitaly Takmazov | 2023-01-13 10:37:54 +0300 |
commit | d97d9ec75c84f604aa06525d8aa75f317bf940c7 (patch) | |
tree | 7a88f73297cff22a8b7a8874839848a446f161e4 /vnext/src | |
parent | 0ffaf5d8d146deb3fe324699284af7eea1de9dc5 (diff) |
Fix Thread without state
Diffstat (limited to 'vnext/src')
-rw-r--r-- | vnext/src/components/Thread.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/vnext/src/components/Thread.js b/vnext/src/components/Thread.js index 1563aa66..87babc1a 100644 --- a/vnext/src/components/Thread.js +++ b/vnext/src/components/Thread.js @@ -80,7 +80,7 @@ Comment.propTypes = { }; export default function Thread(props) { - const [message, setMessage] = useState(props.location.state.msg || {}); + const [message, setMessage] = useState((props.location.state || {}).msg || {}); const [replies, setReplies] = useState([]); const [loading, setLoading] = useState(false); const [active, setActive] = useState(0); |