Add avatar_description and header_description parameters to PATCH /api/v1/profile (#38221)
This commit is contained in:
@@ -25,7 +25,9 @@ class Api::V1::ProfilesController < Api::BaseController
|
|||||||
:display_name,
|
:display_name,
|
||||||
:note,
|
:note,
|
||||||
:avatar,
|
:avatar,
|
||||||
|
:avatar_description,
|
||||||
:header,
|
:header,
|
||||||
|
:header_description,
|
||||||
:locked,
|
:locked,
|
||||||
:bot,
|
:bot,
|
||||||
:discoverable,
|
:discoverable,
|
||||||
|
|||||||
@@ -45,7 +45,7 @@ module Mastodon
|
|||||||
|
|
||||||
def api_versions
|
def api_versions
|
||||||
{
|
{
|
||||||
mastodon: 8,
|
mastodon: 9,
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
@@ -62,6 +62,7 @@ RSpec.describe 'Profile API' do
|
|||||||
let(:params) do
|
let(:params) do
|
||||||
{
|
{
|
||||||
avatar: fixture_file_upload('avatar.gif', 'image/gif'),
|
avatar: fixture_file_upload('avatar.gif', 'image/gif'),
|
||||||
|
avatar_description: 'animated walking round cat',
|
||||||
discoverable: true,
|
discoverable: true,
|
||||||
display_name: "Alice Isn't Dead",
|
display_name: "Alice Isn't Dead",
|
||||||
header: fixture_file_upload('attachment.jpg', 'image/jpeg'),
|
header: fixture_file_upload('attachment.jpg', 'image/jpeg'),
|
||||||
@@ -110,6 +111,7 @@ RSpec.describe 'Profile API' do
|
|||||||
display_name: eq("Alice Isn't Dead"),
|
display_name: eq("Alice Isn't Dead"),
|
||||||
note: 'Hello!',
|
note: 'Hello!',
|
||||||
avatar: exist,
|
avatar: exist,
|
||||||
|
avatar_description: 'animated walking round cat',
|
||||||
header: exist,
|
header: exist,
|
||||||
attribution_domains: ['example.com'],
|
attribution_domains: ['example.com'],
|
||||||
fields: contain_exactly(
|
fields: contain_exactly(
|
||||||
|
|||||||
Reference in New Issue
Block a user