wiki pages: fix error in new controller action.
This commit is contained in:
@@ -166,7 +166,7 @@ class WikiPage < ApplicationRecord
|
||||
end
|
||||
|
||||
def self.is_meta_wiki?(title)
|
||||
title.starts_with?(*META_WIKIS)
|
||||
title.present? && title.starts_with?(*META_WIKIS)
|
||||
end
|
||||
|
||||
def is_meta_wiki?
|
||||
|
||||
@@ -92,6 +92,11 @@ class WikiPagesControllerTest < ActionDispatch::IntegrationTest
|
||||
get_auth new_wiki_page_path, @mod, params: { wiki_page: { title: "test" }}
|
||||
assert_response :success
|
||||
end
|
||||
|
||||
should "render without a title" do
|
||||
get_auth new_wiki_page_path, @mod
|
||||
assert_response :success
|
||||
end
|
||||
end
|
||||
|
||||
context "edit action" do
|
||||
|
||||
Reference in New Issue
Block a user