mirror of
https://github.com/codeninjasllc/discourse.git
synced 2024-11-27 17:46:05 -05:00
toggle_mute
doesn't require a param
This commit is contained in:
parent
bd1b4d3130
commit
8298a07fd9
1 changed files with 3 additions and 3 deletions
|
@ -108,11 +108,11 @@ class TopicsController < ApplicationController
|
||||||
end
|
end
|
||||||
|
|
||||||
def mute
|
def mute
|
||||||
toggle_mute(true)
|
toggle_mute
|
||||||
end
|
end
|
||||||
|
|
||||||
def unmute
|
def unmute
|
||||||
toggle_mute(false)
|
toggle_mute
|
||||||
end
|
end
|
||||||
|
|
||||||
def autoclose
|
def autoclose
|
||||||
|
@ -211,7 +211,7 @@ class TopicsController < ApplicationController
|
||||||
|
|
||||||
private
|
private
|
||||||
|
|
||||||
def toggle_mute(v)
|
def toggle_mute
|
||||||
@topic = Topic.where(id: params[:topic_id].to_i).first
|
@topic = Topic.where(id: params[:topic_id].to_i).first
|
||||||
guardian.ensure_can_see!(@topic)
|
guardian.ensure_can_see!(@topic)
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue