diff --git a/allianceauth/fleetactivitytracking/views.py b/allianceauth/fleetactivitytracking/views.py index 232fa456..ff076e51 100644 --- a/allianceauth/fleetactivitytracking/views.py +++ b/allianceauth/fleetactivitytracking/views.py @@ -320,8 +320,8 @@ def click_fatlink_view(request, token, fat_hash=None): messages.warning( request, _( - f"Cannot register the fleet participation for {character.character_name}. The character needs to be online." - ), + "Cannot register the fleet participation for {character_name}. The character needs to be online." + ).format(character_name=character.character_name) ) return redirect('fatlink:view') diff --git a/allianceauth/services/abstract.py b/allianceauth/services/abstract.py index d6e500e0..4e045ce7 100644 --- a/allianceauth/services/abstract.py +++ b/allianceauth/services/abstract.py @@ -100,7 +100,10 @@ class BaseSetPasswordServiceAccountView(ServicesCRUDMixin, BaseServiceView, Upda def post(self, request, *args, **kwargs): result = super().post(request, *args, **kwargs) if self.get_form().is_valid(): - messages.success(request, _(f"Successfully set your {self.service_name} password")) + messages.success( + request, + _("Successfully set your {service_name} password").format(service_name=self.service_name) + ) return result