Really allow Extensions to make a new gallery format
authorFlorianschmidtwelzow <florian.schmidt.welzow@t-online.de>
Mon, 22 Dec 2014 15:39:52 +0000 (16:39 +0100)
committerUmherirrender <umherirrender_de.wp@web.de>
Mon, 22 Dec 2014 19:09:52 +0000 (19:09 +0000)
Adjust GalleryGetModes call to fit Hooks::run() signature.

Follow up: I33462a8b52502ed76aeb163b66e3704c8618ba23

Change-Id: I916dade31d6d67de4bb82582cc71585e83fec1c9

docs/hooks.txt
includes/gallery/ImageGalleryBase.php

index f83a6c3..8d024d6 100644 (file)
@@ -1261,7 +1261,7 @@ $reason: reason
 
 'GalleryGetModes': Get list of classes that can render different modes of a
  gallery
-$modeArray: An associative array mapping mode names to classes that implement
+&$modeArray: An associative array mapping mode names to classes that implement
  that mode. It is expected all registered classes are a subclass of
  ImageGalleryBase.
 
index bb9a903..2a888a5 100644 (file)
@@ -120,7 +120,7 @@ abstract class ImageGalleryBase extends ContextSource {
                                'packed-overlay' => 'PackedOverlayImageGallery',
                        );
                        // Allow extensions to make a new gallery format.
-                       Hooks::run( 'GalleryGetModes', self::$modeMapping );
+                       Hooks::run( 'GalleryGetModes', array( &self::$modeMapping ) );
                }
        }