pl-api: Support password change on Pixelfed
Signed-off-by: mkljczk <git@mkljczk.pl>
This commit is contained in:
@@ -1296,6 +1296,17 @@ class PlApiClient {
|
||||
body: { new_password },
|
||||
});
|
||||
break;
|
||||
case PIXELFED:
|
||||
response = await this.request('/api/v1.1/accounts/change-password', {
|
||||
method: 'POST',
|
||||
body: {
|
||||
current_password,
|
||||
new_password,
|
||||
confirm_password: new_password,
|
||||
},
|
||||
});
|
||||
if (response.redirected) throw response;
|
||||
break;
|
||||
default:
|
||||
response = await this.request('/api/pleroma/change_password', {
|
||||
method: 'POST',
|
||||
|
||||
@@ -1220,6 +1220,7 @@ const getFeatures = (instance: Instance) => {
|
||||
changePassword: any([
|
||||
v.software === GOTOSOCIAL,
|
||||
v.software === MITRA,
|
||||
v.software === PIXELFED,
|
||||
v.software === PLEROMA,
|
||||
]),
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "pl-api",
|
||||
"version": "1.0.0-rc.8",
|
||||
"version": "1.0.0-rc.9",
|
||||
"type": "module",
|
||||
"homepage": "https://github.com/mkljczk/pl-fe/tree/develop/packages/pl-api",
|
||||
"repository": {
|
||||
|
||||
Reference in New Issue
Block a user