support for extended fields (for future, doesn't work yet), fix reply bug
This commit is contained in:
parent
bac7154bc6
commit
d231a45644
1 changed files with 7 additions and 13 deletions
|
@ -58,14 +58,12 @@ export const parseUser = (data) => {
|
||||||
|
|
||||||
output.statusnet_profile_url = data.url
|
output.statusnet_profile_url = data.url
|
||||||
|
|
||||||
// FIXME missing
|
if (data.pleroma) {
|
||||||
output.follows_you = null
|
const pleroma = data.pleroma
|
||||||
|
output.follows_you = pleroma.follows_you
|
||||||
// FIXME ???????
|
output.statusnet_blocking = pleroma.statusnet_blocking
|
||||||
output.statusnet_blocking = false
|
output.muted = pleroma.muted
|
||||||
|
}
|
||||||
// FIXME missing
|
|
||||||
output.muted = null
|
|
||||||
|
|
||||||
// Missing, trying to recover
|
// Missing, trying to recover
|
||||||
output.is_local = !output.screen_name.includes('@')
|
output.is_local = !output.screen_name.includes('@')
|
||||||
|
@ -204,11 +202,7 @@ export const parseStatus = (data) => {
|
||||||
|
|
||||||
output.user = parseUser(masto ? data.account : data.user)
|
output.user = parseUser(masto ? data.account : data.user)
|
||||||
|
|
||||||
output.attentions = ((masto ? data.mentions : data.attentions) || [])
|
output.attentions = ((masto ? data.mentions : data.attentions) || []).map(parseUser)
|
||||||
.map(_ => ({
|
|
||||||
id: _.id,
|
|
||||||
following: _.following // FIXME: MastoAPI doesn't have this
|
|
||||||
}))
|
|
||||||
|
|
||||||
output.attachments = ((masto ? data.media_attachments : data.attachments) || [])
|
output.attachments = ((masto ? data.media_attachments : data.attachments) || [])
|
||||||
.map(parseAttachment)
|
.map(parseAttachment)
|
||||||
|
|
Loading…
Reference in a new issue