forked from saurabh/personal-conference
Fix author text bug.
This commit is contained in:
parent
45adef9eac
commit
2d5938458a
|
@ -10,7 +10,7 @@ module Admin::PersonalConferencesHelper
|
||||||
end
|
end
|
||||||
full_authors_names = get_member(writing_conference).collect do |member|
|
full_authors_names = get_member(writing_conference).collect do |member|
|
||||||
member_name = member.name
|
member_name = member.name
|
||||||
idx = authors_names.index{|a| a.match(/(^|[ \(\[])#{member_name}([ \)\]\*]|$)/)}
|
idx = authors_names.index{|a| a.match(/(^|[ \(\[])#{::Regexp.escape(member_name)}([ \)\]\*]|$)/)}
|
||||||
if idx
|
if idx
|
||||||
member_name = authors_names[idx]
|
member_name = authors_names[idx]
|
||||||
authors_names[idx] = nil
|
authors_names[idx] = nil
|
||||||
|
@ -31,7 +31,7 @@ module Admin::PersonalConferencesHelper
|
||||||
end
|
end
|
||||||
full_authors = get_member(writing_conference).collect do |member|
|
full_authors = get_member(writing_conference).collect do |member|
|
||||||
member_name = member.name
|
member_name = member.name
|
||||||
idx = authors_names.index{|a| a.match(/(^|[ \(\[])#{member_name}([ \)\]\*]|$)/)}
|
idx = authors_names.index{|a| a.match(/(^|[ \(\[])#{::Regexp.escape(member_name)}([ \)\]\*]|$)/)}
|
||||||
if idx
|
if idx
|
||||||
member_name = authors_names[idx]
|
member_name = authors_names[idx]
|
||||||
authors_names[idx] = nil
|
authors_names[idx] = nil
|
||||||
|
|
Loading…
Reference in New Issue