+
+/*
+ * This is a hack to hardcode opestreetmap.org -> osm.org in the
+ * shortlink
+ */
+function shortlinkPrefix() {
+ var hostname = window.location.hostname;
+ var normalized_hostname = hostname.replace(/^:www\./i,'');
+ var prefix = '';
+
+ if (normalized_hostname.match(/^openstreetmap\.org$/i)) {
+ prefix = "http://osm.org";
+ }
+
+ return prefix;
+}
+