Cannot merge tickets. Undefined method ‘id’ for nil:NilClass

Infos:

  • Used Zammad version: 5.1.1-1654175602.81408f7e.focal
  • Used Zammad installation type: package
  • Operating system: Ubuntu 20.04.4 LTS
  • Browser + version: Google Chrome Version 102.0.5005.63

Expected behavior:

  • Go to ticket, click on “Ticket” menu and choose Merge.
    Choose ticket to Merge with.
    Tickets are Merged.

Actual behavior:

  • When I click Merge I get the following error
# StatusCode: 500
undefined method `id' for nil:NilClass

Steps to reproduce the behavior:

  • Go to ticket, click on “Ticket” menu and choose Merge.
    Choose ticket to Merge with.

Log output

[2022-06-06T10:58:23.327374 #496471-701340]  INFO -- : Completed 500 Internal Server Error in 265ms (Views: 0.3ms | ActiveRecord: 59.4ms | Allocations: 48555)

I need solution for this with urgency, plis

I still can’t solve the problem, please, what can I do?