From 5de746a482df4fd4e3d9ce70c9bb281d14e99a2a Mon Sep 17 00:00:00 2001 From: Chris Schlaeger Date: Sat, 5 Nov 2016 14:17:05 +0100 Subject: Move pr_trackview_init_xy() call before init_viewframe_map(). This hopefully fixes some issues with the maps not showing up for some users. --- lib/postrunner/TrackView.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'lib') diff --git a/lib/postrunner/TrackView.rb b/lib/postrunner/TrackView.rb index 3500972..58f3644 100644 --- a/lib/postrunner/TrackView.rb +++ b/lib/postrunner/TrackView.rb @@ -33,6 +33,8 @@ module PostRunner def to_html(doc) return unless @has_geo_data + doc.body_init_script('pr_trackview_init_xy();') + doc.head { doc.unique(:trackview_style) { doc.style(style) @@ -51,7 +53,6 @@ module PostRunner doc.div({ 'id' => 'map', 'class' => 'trackmap' }) }.to_html(doc) - doc.body_init_script('pr_trackview_init_xy();') end private -- cgit v1.2.3