]> git.openstreetmap.org Git - rails.git/blobdiff - lib/potlatch.rb
lighttpd increase server.max-fds from 1024 (default) to 8192 after lighttpd deadlock.
[rails.git] / lib / potlatch.rb
index ebafbce0086c809e5668899378bf3f4bbb456b85..cfb6028177e1579e5ed3f1e014768864d938eed1 100644 (file)
@@ -147,7 +147,7 @@ module Potlatch
             presetcategory=$2
             presetmenus[presettype].push(presetcategory)
             presetnames[presettype][presetcategory]=["(no preset)"]
             presetcategory=$2
             presetmenus[presettype].push(presetcategory)
             presetnames[presettype][presetcategory]=["(no preset)"]
-          elsif (t=~/^(.+):\s?(.+)$/) then
+          elsif (t=~/^([\w\s]+):\s?(.+)$/) then
             pre=$1; kv=$2
             presetnames[presettype][presetcategory].push(pre)
             presets[pre]={}
             pre=$1; kv=$2
             presetnames[presettype][presetcategory].push(pre)
             presets[pre]={}
@@ -191,7 +191,7 @@ module Potlatch
       File.open("#{RAILS_ROOT}/config/potlatch/autocomplete.txt") do |file|
         file.each_line {|line|
           t=line.chomp
       File.open("#{RAILS_ROOT}/config/potlatch/autocomplete.txt") do |file|
         file.each_line {|line|
           t=line.chomp
-          if (t=~/^(\w+)\/(\w+)\s+(.+)$/) then
+          if (t=~/^([\w:]+)\/(\w+)\s+(.+)$/) then
             tag=$1; type=$2; values=$3
             if values=='-' then autotags[type][tag]=[]
             else autotags[type][tag]=values.split(',').sort.reverse end
             tag=$1; type=$2; values=$3
             if values=='-' then autotags[type][tag]=[]
             else autotags[type][tag]=values.split(',').sort.reverse end