Defect #10275

Message object not passed to wiki macros for head topic and in preview edit mode

Added by Vitaly Klimov almost 6 years ago. Updated over 5 years ago.

Status:ClosedStart date:
Priority:NormalDue date:
Assignee:Jean-Philippe Lang% Done:

0%

Category:Forums
Target version:1.4.0
Resolution:Fixed Affected version:

Description

nil passed instead of message object to wiki macros in textilizable function for head topic or for preview in edit mode. It is caused by inproper call to textilizable in messages\show.html.erb, line 30:

<%= textilizable(@topic.content, :attachments => @topic.attachments) %>

It should be corrected to

<%= textilizable(@topic, :content, :attachments => @topic.attachments) %>

For edit mode preview:

in file messages\edit.html.erb, line 15 should be changed from

:action => 'preview', :board_id => @board },

to

:action => 'preview', :board_id => @board, :id => message },

for correct message variable calculation in MessagesController.preview method

Associated revisions

Revision 8949
Added by Jean-Philippe Lang over 5 years ago

Pass the topic objet to #textilizable (#10275).

Revision 8950
Added by Jean-Philippe Lang over 5 years ago

Pass the message id when previewing in edit mode (#10275).

History

#1 Updated by Vitaly Klimov almost 6 years ago

Small fix - last correction should be

:action => 'preview', :board_id => @board, :id => @message },

#2 Updated by Etienne Massip almost 6 years ago

  • Category changed from Forums to Wiki
  • Assignee deleted (Jean-Philippe Lang)

Please don't assign issues.

#3 Updated by Jean-Philippe Lang over 5 years ago

  • Category changed from Wiki to Forums
  • Status changed from New to Closed
  • Assignee set to Jean-Philippe Lang
  • Target version set to 1.4.0
  • Resolution set to Fixed

Fixed in r8949 and r8950.

Also available in: Atom PDF