mirror of
https://github.com/discourse/discourse.git
synced 2025-05-21 18:12:32 +08:00
FEATURE: allow users to wikify their own posts based on trust level
This commit is contained in:
@ -305,9 +305,9 @@ class PostsController < ApplicationController
|
||||
end
|
||||
|
||||
def wiki
|
||||
guardian.ensure_can_wiki!
|
||||
|
||||
post = find_post_from_params
|
||||
guardian.ensure_can_wiki!(post)
|
||||
|
||||
post.revise(current_user, { wiki: params[:wiki] })
|
||||
|
||||
render nothing: true
|
||||
|
Reference in New Issue
Block a user