mirror of
https://codeberg.org/rimu/pyfedi
synced 2025-02-03 00:31:25 -08:00
show users based on id
This commit is contained in:
parent
fb046f1acb
commit
48bc683a6a
1 changed files with 6 additions and 0 deletions
|
@ -34,6 +34,12 @@ def show_people():
|
|||
joined_communities=joined_communities(current_user.get_id()), title=_('People'))
|
||||
|
||||
|
||||
@bp.route('/user/<int:user_id>', methods=['GET'])
|
||||
def show_profile_by_id(user_id):
|
||||
user = User.query.get_or_404(user_id)
|
||||
return show_profile(user)
|
||||
|
||||
|
||||
def show_profile(user):
|
||||
if (user.deleted or user.banned) and current_user.is_anonymous:
|
||||
abort(404)
|
||||
|
|
Loading…
Add table
Reference in a new issue