Skip to content
Snippets Groups Projects
Commit ba5e98bb authored by Douwe Maan's avatar Douwe Maan
Browse files

Backport Note#commands_changes from EE

parent d0c0c75c
No related branches found
No related tags found
No related merge requests found
Loading
Loading
@@ -197,6 +197,7 @@ class Projects::NotesController < Projects::ApplicationController
)
end
 
attrs[:commands_changes] = note.commands_changes unless attrs[:award]
attrs
end
 
Loading
Loading
Loading
Loading
@@ -19,6 +19,9 @@ class Note < ActiveRecord::Base
# Banzai::ObjectRenderer
attr_accessor :user_visible_reference_count
 
# Attribute used to store the attributes that have ben changed by slash commands.
attr_accessor :commands_changes
default_value_for :system, false
 
attr_mentionable :note, pipeline: :note
Loading
Loading
Loading
Loading
@@ -43,6 +43,8 @@ module Notes
if only_commands
note.errors.add(:commands_only, 'Your commands have been executed!')
end
note.commands_changes = command_params.keys
end
 
note
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment