projects
/
rails.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8688edf
)
Match wikipedia language prefixes case insensitively
author
Paweł Paprota
<ppawel@fastmail.fm>
Fri, 5 Oct 2012 18:38:46 +0000
(20:38 +0200)
committer
Tom Hughes
<tom@compton.nu>
Sun, 7 Oct 2012 15:03:10 +0000
(16:03 +0100)
Without this values like "PL:Article" are linked to the English Wikipedia.
app/helpers/browse_helper.rb
patch
|
blob
|
history
diff --git
a/app/helpers/browse_helper.rb
b/app/helpers/browse_helper.rb
index ea17b8202d1a9a4ac7b9493c8deb234aa00a34b7..c4e4d425a5ef997a97dbb84cc2d75eeac53a5cac 100644
(file)
--- a/
app/helpers/browse_helper.rb
+++ b/
app/helpers/browse_helper.rb
@@
-97,7
+97,7
@@
private
if key == "wikipedia"
# This regex should match Wikipedia language codes, everything
# from de to zh-classical
- if value =~ /^([a-z-]{2,12}):(.+)$/
+ if value =~ /^([a-z-]{2,12}):(.+)$/
i
# Value is <lang>:<title> so split it up
# Note that value is always left as-is, see: https://trac.openstreetmap.org/ticket/4315
lang = $1