don't try to initialize the mapstraction canvas if it doesn't exist

This commit is contained in:
Evan Prodromou 2010-11-12 11:46:45 -05:00
parent 09aaf21e8d
commit b6af5a25ba
1 changed files with 2 additions and 1 deletions

View File

@ -156,7 +156,8 @@ class MapstractionPlugin extends Plugin
' var user = null; '.
(($actionName == 'showstream') ? ' user = scrapeUser(); ' : '') .
' var notices = scrapeNotices(user); ' .
' showMapstraction($("#map_canvas"), notices); '.
' var canvas = $("#map_canvas")[0]; ' .
' if (typeof(canvas) != "undefined") { showMapstraction(canvas, notices); } '.
'});');
}