TheDJ has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/367109 )

Change subject: StaticMap: fix error on multiple wikipage.content
......................................................................

StaticMap: fix error on multiple wikipage.content

The cleanup routine here was copied from mapframe, but this is
actually similar to maplink. .remove() would throw a TypeError,
because we are storing Link objects here not Maps and only Maps have
the remove() function.

Bug: T159295
Change-Id: I73cd6415813a74129dbd2595da4a9b2bf61012b1
---
M modules/staticframe/staticframe.js
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Kartographer 
refs/changes/09/367109/1

diff --git a/modules/staticframe/staticframe.js 
b/modules/staticframe/staticframe.js
index d22621f..32cff03 100644
--- a/modules/staticframe/staticframe.js
+++ b/modules/staticframe/staticframe.js
@@ -69,7 +69,7 @@
 
                // `wikipage.content` may be fired more than once.
                $.each( maps, function () {
-                       maps.pop().remove();
+                       maps.pop().$container.off( 'click.kartographer' );
                } );
 
                $content.find( '.mw-kartographer-map' ).each( function ( index 
) {

-- 
To view, visit https://gerrit.wikimedia.org/r/367109
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I73cd6415813a74129dbd2595da4a9b2bf61012b1
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Kartographer
Gerrit-Branch: master
Gerrit-Owner: TheDJ <hartman.w...@gmail.com>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to