Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
conduwuit
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
🥺
conduwuit
Commits
4db6d7e4
Unverified
Commit
4db6d7e4
authored
4 years ago
by
Timo Kösters
Browse files
Options
Downloads
Patches
Plain Diff
fix: remove avatar url checks
They are not in the spec and maubot relies on that
parent
a567cd81
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/client_server/profile.rs
+0
-12
0 additions, 12 deletions
src/client_server/profile.rs
with
0 additions
and
12 deletions
src/client_server/profile.rs
+
0
−
12
View file @
4db6d7e4
...
...
@@ -119,18 +119,6 @@ pub async fn set_avatar_url_route(
)
->
ConduitResult
<
set_avatar_url
::
Response
>
{
let
sender_id
=
body
.sender_id
.as_ref
()
.expect
(
"user is authenticated"
);
if
let
Some
(
avatar_url
)
=
&
body
.avatar_url
{
if
!
avatar_url
.starts_with
(
"mxc://"
)
{
return
Err
(
Error
::
BadRequest
(
ErrorKind
::
InvalidParam
,
"avatar_url has to start with mxc://."
,
));
}
// TODO in the future when we can handle media uploads make sure that this url is our own server
// TODO also make sure this is valid mxc:// format (not only starting with it)
}
db
.users
.set_avatar_url
(
&
sender_id
,
body
.avatar_url
.clone
())
?
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment