Skip to content

Commit

Permalink
core: frontend: components: StatusTextWatcher: Use last
Browse files Browse the repository at this point in the history
Signed-off-by: Patrick José Pereira <patrickelectric@gmail.com>
  • Loading branch information
patrickelectric committed Mar 26, 2024
1 parent af541ce commit f471457
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/frontend/src/components/common/StatusTextWatcher.vue
Expand Up @@ -34,7 +34,7 @@ export default {
mounted() {
this.listener = mavlink2rest.startListening('STATUSTEXT').setCallback((receivedMessage) => {
const text = receivedMessage.message.text.join('')
if (this.messages?.[this.messages.length - 1] === text) {
if (this.messages?.last() === text) {
return
}
if (new RegExp(this.filter).test(text)) {
Expand Down

0 comments on commit f471457

Please sign in to comment.