Index: trunk/extensions/Collection/Collection.php |
— | — | @@ -130,6 +130,9 @@ |
131 | 131 | $wgHooks['SkinBuildSidebar'][] = 'CollectionHooks::buildSidebar'; |
132 | 132 | $wgHooks['OutputPageCheckLastModified'][] = 'CollectionHooks::checkLastModified'; |
133 | 133 | |
| 134 | +$wgAvailableRights[] = 'collectionsaveasuserpage'; |
| 135 | +$wgAvailableRights[] = 'collectionsaveascommunitypage'; |
| 136 | + |
134 | 137 | # register global Ajax functions: |
135 | 138 | |
136 | 139 | function wfAjaxGetCollection() { |
Index: trunk/extensions/Collection/Collection.body.php |
— | — | @@ -293,14 +293,14 @@ |
294 | 294 | $new_items = array(); |
295 | 295 | foreach ( $collection['items'] as $item ) { |
296 | 296 | if ( $item['type'] == 'chapter' ) { |
297 | | - usort( $articles, array( self, 'title_cmp' ) ); |
| 297 | + usort( $articles, array( __CLASS__, 'title_cmp' ) ); |
298 | 298 | $new_items = array_merge( $new_items, $articles, array( $item ) ); |
299 | 299 | $articles = array(); |
300 | 300 | } elseif ( $item['type'] == 'article' ) { |
301 | 301 | $articles[] = $item; |
302 | 302 | } |
303 | 303 | } |
304 | | - usort( $articles, array( self, 'title_cmp' ) ); |
| 304 | + usort( $articles, array( __CLASS__, 'title_cmp' ) ); |
305 | 305 | $collection['items'] = array_merge( $new_items, $articles ); |
306 | 306 | $_SESSION['wsCollection'] = $collection; |
307 | 307 | CollectionSession::touchSession(); |