Skip to content
Snippets Groups Projects
Commit dc8f32f2 authored by Nik | Klampfradler's avatar Nik | Klampfradler
Browse files

Merge branch '151-force-__str__-methods-to-return-strings' into 'master'

Resolve "Force __str__ methods to return strings"

Closes #151

See merge request AlekSIS/official/AlekSIS-App-Chronos!198
parents 089837e8 bdb9ee9a
No related branches found
No related tags found
No related merge requests found
......@@ -6,6 +6,14 @@ All notable changes to this project will be documented in this file.
The format is based on `Keep a Changelog`_,
and this project adheres to `Semantic Versioning`_.
Unreleased
----------
Fixed
~~~~~
* ``Event.__str__`` returned a proxy type instead a string.
`2.0rc2`_ - 2021-08-01
----------
......
......@@ -976,7 +976,7 @@ class Event(SchoolTermRelatedExtensibleModel, GroupPropertiesMixin, TeacherPrope
if self.title:
return self.title
else:
return _(f"Event {self.pk}")
return _("Event {pk}").format(pk=self.pk)
@property
def raw_period_from_on_day(self) -> TimePeriod:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment