From d1cf47c8c60e4d59d6f5e78af3bd7827196e3c24 Mon Sep 17 00:00:00 2001 From: Makurin Date: Tue, 8 Nov 2022 13:21:51 +0300 Subject: [PATCH] WikiController raises a `undefined method `custom_workflow_messages' for #` error if `@content` assigned to the WikiContentVersion. Since plugin doesn't support WikiContentVersion just skip it. --- .../patches/controllers/wiki_controller_patch.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/redmine_custom_workflows/patches/controllers/wiki_controller_patch.rb b/lib/redmine_custom_workflows/patches/controllers/wiki_controller_patch.rb index be52329..62dea0f 100644 --- a/lib/redmine_custom_workflows/patches/controllers/wiki_controller_patch.rb +++ b/lib/redmine_custom_workflows/patches/controllers/wiki_controller_patch.rb @@ -73,7 +73,9 @@ module RedmineCustomWorkflows elsif @page objects = [@page] end - if @content + # @content either WikiContent or WikiContentVersion + # but plugin does not patch nor work with WikiContentVersion + if @content.is_a? WikiContent objects ||= [] objects << @content end