Ensure selectedItem has a value
This commit is contained in:
parent
9f4e07d5a5
commit
9306e6cbe6
@ -424,7 +424,7 @@
|
||||
.then(res => res.json())
|
||||
.then(items => {
|
||||
if (!this.showRead) {
|
||||
if (!items.some(i => i.ID == this.selectedItem)) {
|
||||
if (this.selectedItem && !items.some(i => i.ID == this.selectedItem)) {
|
||||
items.unshift(this.items.find(i => i.ID == this.selectedItem));
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user