Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Pleroma
pleroma
Commits
16f8406e
Commit
16f8406e
authored
May 02, 2017
by
lain
Browse files
Add statusnet_profile_url to the TwAPI.
parent
32a95d73
Changes
2
Hide whitespace changes
Inline
Side-by-side
lib/pleroma/web/twitter_api/representers/user_representer.ex
View file @
16f8406e
...
...
@@ -28,7 +28,8 @@ def to_map(user, opts) do
"profile_image_url_https"
=>
image
,
"profile_image_url_profile_size"
=>
image
,
"profile_image_url_original"
=>
image
,
"rights"
=>
%{}
"rights"
=>
%{},
"statusnet_profile_url"
=>
user
.
ap_id
}
map
...
...
test/web/twitter_api/representers/user_representer_test.exs
View file @
16f8406e
...
...
@@ -48,7 +48,8 @@ test "A user" do
"profile_image_url_profile_size"
=>
image
,
"profile_image_url_original"
=>
image
,
"following"
=>
false
,
"rights"
=>
%{}
"rights"
=>
%{},
"statusnet_profile_url"
=>
user
.
ap_id
}
assert
represented
==
UserRepresenter
.
to_map
(
user
)
...
...
@@ -72,7 +73,8 @@ test "A user for a given other follower", %{user: user} do
"profile_image_url_profile_size"
=>
image
,
"profile_image_url_original"
=>
image
,
"following"
=>
true
,
"rights"
=>
%{}
"rights"
=>
%{},
"statusnet_profile_url"
=>
user
.
ap_id
}
assert
represented
==
UserRepresenter
.
to_map
(
user
,
%{
for:
follower
})
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment