Merge branch 'fix/gs-emoji-error' into 'develop'
Suppress emoji fetch error on gs. See merge request pleroma/pleroma-fe!183
This commit is contained in:
commit
fe269b2cf9
1 changed files with 13 additions and 7 deletions
20
src/main.js
20
src/main.js
|
@ -129,10 +129,16 @@ window.fetch('/static/terms-of-service.html')
|
||||||
})
|
})
|
||||||
|
|
||||||
window.fetch('/api/pleroma/emoji.json')
|
window.fetch('/api/pleroma/emoji.json')
|
||||||
.then((res) => res.json())
|
.then(
|
||||||
.then((values) => {
|
(res) => res.json()
|
||||||
const emoji = Object.keys(values).map((key) => {
|
.then(
|
||||||
return { shortcode: key, image_url: values[key] }
|
(values) => {
|
||||||
})
|
const emoji = Object.keys(values).map((key) => {
|
||||||
store.dispatch('setOption', { name: 'emoji', value: emoji })
|
return { shortcode: key, image_url: values[key] }
|
||||||
})
|
})
|
||||||
|
store.dispatch('setOption', { name: 'emoji', value: emoji })
|
||||||
|
},
|
||||||
|
(failure) => {}
|
||||||
|
),
|
||||||
|
(error) => console.log(error)
|
||||||
|
)
|
||||||
|
|
Loading…
Reference in a new issue