Project

General

Profile

Actions

Defect #26627

closed

Editing issues no longer sends notifications to previous assignee

Added by Rocket Lee over 7 years ago. Updated about 7 years ago.

Status:
Closed
Priority:
Normal
Category:
Issues
Target version:
Start date:
Due date:
% Done:

0%

Estimated time:
Resolution:
Fixed
Affected version:

Description

Editing issues no longer sends notifications to previous assignee.

This is happening because of the change made in #25794, which changed app/models/journal.rb from after_create :send_notification to after_commit :send_notification, :on => :create. This is causing clear_assigned_to_was() in app/models/issue.rb to be called before the notifications are being generated and so the previous assignee variable is already set to nil when it's time to send the notification. after_commit runs too late.

I know this affects up through 3.4.2, but I don't know how it affects the new master.

Here's the specific line change: https://github.com/redmine/redmine/commit/9439cae70fab58b8cafdd753aa83135d4279345d#diff-b3b2ca7a3d44a3146792e51535d4acd5


Related issues

Related to Redmine - Defect #25794: Mass-deleted attachments are not represented correctly in email notificationsClosedJean-Philippe Lang

Actions
Has duplicate Redmine - Defect #26628: When assignee change, previous assignee did't notifiedClosed

Actions
Actions #1

Updated by Toshi MARUYAMA over 7 years ago

  • Related to Defect #25794: Mass-deleted attachments are not represented correctly in email notifications added
Actions #2

Updated by Toshi MARUYAMA over 7 years ago

  • Status changed from New to Confirmed
  • Target version set to 3.4.3

Confirmed.
I don't know why "test_update_should_notify_previous_assignee" does not catch.
source:tags/3.4.2/test/unit/issue_test.rb#L2441

Actions #3

Updated by Go MAEDA over 7 years ago

  • Has duplicate Defect #26628: When assignee change, previous assignee did't notified added
Actions #4

Updated by Jean-Philippe Lang about 7 years ago

  • Assignee set to Jean-Philippe Lang
  • Resolution set to Fixed

Fixed in r17002.

Actions #5

Updated by Jean-Philippe Lang about 7 years ago

  • Status changed from Confirmed to Closed
Actions #6

Updated by Rocket Lee about 7 years ago

Thank you!

Actions

Also available in: Atom PDF