mirror of
https://github.com/meineerde/redmine.git
synced 2025-12-22 00:11:14 +00:00
Modify circular inclusion test to use page.id instead of page.title (#24869).
Patch by Michael Esemplare. git-svn-id: http://svn.redmine.org/redmine/trunk@16227 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
parent
e8d7b36f1b
commit
df5dba5dde
@ -207,8 +207,8 @@ module Redmine
|
||||
page = Wiki.find_page(args.first.to_s, :project => @project)
|
||||
raise 'Page not found' if page.nil? || !User.current.allowed_to?(:view_wiki_pages, page.wiki.project)
|
||||
@included_wiki_pages ||= []
|
||||
raise 'Circular inclusion detected' if @included_wiki_pages.include?(page.title)
|
||||
@included_wiki_pages << page.title
|
||||
raise 'Circular inclusion detected' if @included_wiki_pages.include?(page.id)
|
||||
@included_wiki_pages << page.id
|
||||
out = textilizable(page.content, :text, :attachments => page.attachments, :headings => false)
|
||||
@included_wiki_pages.pop
|
||||
out
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user