Project

General

Profile

Defect #10413 » 0001-Fix-6991-ampersand-in-pagename.patch

Alexander Oryol, 2012-05-17 13:23

View differences:

app/helpers/application_helper.rb
603 603
    text.gsub!(/(!)?(\[\[([^\]\n\|]+)(\|([^\]\n\|]+))?\]\])/) do |m|
604 604
      link_project = project
605 605
      esc, all, page, title = $1, $2, $3, $5
606
      page.gsub!(/&/, '&')
606 607
      if esc.nil?
607 608
        if page =~ /^([^\:]+)\:(.*)$/
608 609
          link_project = Project.find_by_identifier($1) || Project.find_by_name($1)
(1-1/2)