Replace /api/externalprofile/show.json
with a MastoAPI equialent
`/api/v1/accounts/:id` supports remote nicknames since pleroma!1622
This commit is contained in:
parent
49159e6db3
commit
457290e81e
4 changed files with 2 additions and 15 deletions
|
@ -4,7 +4,6 @@ import 'whatwg-fetch'
|
|||
import { RegistrationError, StatusCodeError } from '../errors/errors'
|
||||
|
||||
/* eslint-env browser */
|
||||
const EXTERNAL_PROFILE_URL = '/api/externalprofile/show.json'
|
||||
const QVITTER_USER_NOTIFICATIONS_READ_URL = '/api/qvitter/statuses/notifications/read.json'
|
||||
const BLOCKS_IMPORT_URL = '/api/pleroma/blocks_import'
|
||||
const FOLLOW_IMPORT_URL = '/api/pleroma/follow_import'
|
||||
|
@ -220,14 +219,6 @@ const authHeaders = (accessToken) => {
|
|||
}
|
||||
}
|
||||
|
||||
const externalProfile = ({ profileUrl, credentials }) => {
|
||||
let url = `${EXTERNAL_PROFILE_URL}?profileurl=${profileUrl}`
|
||||
return fetch(url, {
|
||||
headers: authHeaders(credentials),
|
||||
method: 'GET'
|
||||
}).then((data) => data.json())
|
||||
}
|
||||
|
||||
const followUser = ({ id, credentials }) => {
|
||||
let url = MASTODON_FOLLOW_URL(id)
|
||||
return fetch(url, {
|
||||
|
@ -966,7 +957,6 @@ const apiService = {
|
|||
updateBg,
|
||||
updateProfile,
|
||||
updateBanner,
|
||||
externalProfile,
|
||||
importBlocks,
|
||||
importFollows,
|
||||
deleteAccount,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue