Skip to content

Commit

Permalink
Merge pull request bookwyrm-social#3224 from hughrun/move-fix
Browse files Browse the repository at this point in the history
Pass correct user id in Move notification
  • Loading branch information
mouse-reeve authored Jan 17, 2024
2 parents a585321 + b990d9c commit 61a6ee2
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion bookwyrm/templates/moved.html
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@

<div class="notification is-warning">
<p>
{% id_to_username request.user.moved_to as username %}
{% id_to_username request.user.moved_to as username %}
{% blocktrans trimmed with moved_to=user.moved_to %}
<strong>You have moved your account</strong> to <a href="{{ moved_to }}">{{ username }}</a>
{% endblocktrans %}
Expand Down
2 changes: 1 addition & 1 deletion bookwyrm/templates/notifications/items/move_user.html
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@

{% block description %}
{% if related_user_moved_to %}
{% id_to_username request.user.moved_to as username %}
{% id_to_username related_user_moved_to as username %}
{% blocktrans trimmed %}
{{ related_user }} has moved to <a href="{{ related_user_moved_to }}">{{ username }}</a>
{% endblocktrans %}
Expand Down
3 changes: 2 additions & 1 deletion bookwyrm/templatetags/utilities.py
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,8 @@ def id_to_username(user_id):
name = parts[-1]
value = f"{name}@{domain}"

return value
return value
return "a new user account"


@register.filter(name="get_file_size")
Expand Down

0 comments on commit 61a6ee2

Please sign in to comment.