FIX: Check `postStream.gaps` exists before trying `postSteam.gaps.after`

This commit is contained in:
David Taylor 2019-06-11 23:48:21 +01:00
parent 23f457b87d
commit 0ebe5ec1f8
1 changed files with 1 additions and 0 deletions

View File

@ -115,6 +115,7 @@ export default class {
!stream.canAppendMore && // We are at the end of the stream
stream.posts.lastObject && // The last post exists
stream.posts.lastObject.read && // The last post is read
stream.gaps && // The stream has gaps
!!stream.gaps.after[stream.posts.lastObject.id] && // Stream ends with a gap
stream.topic.last_read_post_number !==
stream.posts.lastObject.post_number +