Skip to content

Commit

Permalink
Correctly handle note imports in existing events
Browse files Browse the repository at this point in the history
  • Loading branch information
tomasr8 authored and ThiefMaster committed Jun 23, 2021
1 parent 9fcce8b commit b6e42b8
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 2 additions & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,8 @@ Bugfixes
- Fix error when exporting a conference timetable PDF with the option "Print abstract content of all
contributions" and one of the abstracts is too big to fit in a page (:issue:`4881`, :pr:`4955`)
- Emails sent via the Editing module are now logged to the event log (:pr:`4960`)
- Fix error when importing event notes from another event while the target event already
has a deleted note (:pr:`4959`)

Internal Changes
^^^^^^^^^^^^^^^^
Expand Down
4 changes: 2 additions & 2 deletions indico/modules/events/notes/clone.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,5 +67,5 @@ def _clone_notes(self, new_event):

def _clone_note(self, old_note, new_object):
revision = old_note.current_revision
new_object.note = EventNote()
new_object.note.create_revision(render_mode=revision.render_mode, source=revision.source, user=revision.user)
note = EventNote.get_or_create(new_object)
note.create_revision(render_mode=revision.render_mode, source=revision.source, user=revision.user)

0 comments on commit b6e42b8

Please sign in to comment.