mirror of
https://github.com/Start9Labs/start-os.git
synced 2026-03-30 12:11:56 +00:00
cleaner
This commit is contained in:
committed by
Aiden McClelland
parent
258727f6b9
commit
023507c06f
@@ -54,12 +54,12 @@ export class MarketplaceListPage {
|
||||
])
|
||||
this.eos = eos
|
||||
this.data = data
|
||||
this.data.categories.unshift('updates')
|
||||
if (data.categories.includes(this.category)) {
|
||||
data.categories = data.categories.filter(cat => this.category !== cat)
|
||||
}
|
||||
data.categories.unshift(this.category)
|
||||
data.categories.push('all')
|
||||
|
||||
// category should start as first item in array
|
||||
// remove here then add at beginning
|
||||
const filterdCategories = this.data.categories.filter(cat => this.category !== cat)
|
||||
this.data.categories = [this.category, 'updates'].concat(filterdCategories).concat(['all'])
|
||||
|
||||
} catch (e) {
|
||||
console.error(e)
|
||||
this.errToast.present(e.message)
|
||||
|
||||
Reference in New Issue
Block a user