prevent infinite update loops

This commit is contained in:
Henry Jameson 2021-08-15 02:55:45 +03:00 committed by Sam Therapy
parent 1202102e0e
commit 5c1789dbc7
Signed by: sam
GPG key ID: 4D8B07C18F31ACBD

View file

@ -33,7 +33,8 @@ const StatusContent = {
showingLongSubject: false,
// not as computed because it sets the initial state which will be changed later
expandingSubject: !this.$store.getters.mergedConfig.collapseMessageWithSubject,
postLength: this.status.text.length
postLength: this.status.text.length,
parseReadyDone: false
}
},
computed: {
@ -86,6 +87,8 @@ const StatusContent = {
},
methods: {
onParseReady (event) {
if (this.parseReadyDone) return
this.parseReadyDone = true
this.$emit('parseReady', event)
const { writtenMentions, invisibleMentions } = event
writtenMentions