diff --git a/app/controllers/wiki_controller.rb b/app/controllers/wiki_controller.rb index fe53e63f2..7609323f4 100644 --- a/app/controllers/wiki_controller.rb +++ b/app/controllers/wiki_controller.rb @@ -31,8 +31,13 @@ class WikiController < ApplicationController page_title = params[:page] @page = @wiki.find_or_new_page(page_title) if @page.new_record? - edit - render :action => 'edit' and return + if User.current.allowed_to?(:edit_wiki_pages, @project) + edit + render :action => 'edit' + else + render_404 + end + return end @content = @page.content_for_version(params[:version]) if params[:export] == 'html'