mirror of
https://github.com/openstreetmap/openstreetmap-website.git
synced 2025-08-01 16:47:18 +00:00
Use full list of osm xml root attributes in builder templates
This commit is contained in:
16
lib/osm.rb
16
lib/osm.rb
@ -494,14 +494,20 @@ module OSM
|
||||
doc = XML::Document.new
|
||||
doc.encoding = XML::Encoding::UTF_8
|
||||
root = XML::Node.new "osm"
|
||||
root["version"] = API_VERSION.to_s
|
||||
root["generator"] = GENERATOR
|
||||
root["copyright"] = COPYRIGHT_OWNER
|
||||
root["attribution"] = ATTRIBUTION_URL
|
||||
root["license"] = LICENSE_URL
|
||||
xml_root_attributes.each do |k, v|
|
||||
root[k] = v
|
||||
end
|
||||
doc.root = root
|
||||
doc
|
||||
end
|
||||
|
||||
def xml_root_attributes
|
||||
{ "version" => API_VERSION.to_s,
|
||||
"generator" => GENERATOR,
|
||||
"copyright" => COPYRIGHT_OWNER,
|
||||
"attribution" => ATTRIBUTION_URL,
|
||||
"license" => LICENSE_URL }
|
||||
end
|
||||
end
|
||||
|
||||
def self.ip_to_country(ip_address)
|
||||
|
Reference in New Issue
Block a user