Index: trunk/extensions/SemanticForms/specials/SF_UploadWindow2.php |
— | — | @@ -955,9 +955,15 @@ |
956 | 956 | $wgTitle = SpecialPage::getTitleFor( 'Upload' ); |
957 | 957 | |
958 | 958 | if ( method_exists( $wgOut, 'addModules' ) ) { |
959 | | - $head_scripts = ''; |
960 | 959 | $wgOut->addModules( array( 'mediawiki.action.edit', 'mediawiki.legacy.upload', 'mediawiki.legacy.wikibits', 'mediawiki.legacy.ajax' ) ); |
961 | | - $body_scripts = $wgOut->getHeadScripts( $sk ); |
| 960 | + // Method was added in MW 1.18 |
| 961 | + if ( method_exists( $wgOut, 'getBottomScripts' ) ) { |
| 962 | + $head_scripts = $wgOut->getHeadScripts( $sk ); |
| 963 | + $body_scripts = $wgOut->getBottomScripts( $sk ); |
| 964 | + } else { |
| 965 | + $head_scripts = ''; |
| 966 | + $body_scripts = $wgOut->getHeadScripts( $sk ); |
| 967 | + } |
962 | 968 | } else { |
963 | 969 | global $wgJsMimeType, $wgStylePath, $wgStyleVersion; |
964 | 970 | $vars_js = Skin::makeGlobalVariablesScript( array( 'skinname' => $sk->getSkinName() ) ); |
— | — | @@ -1133,4 +1139,4 @@ |
1134 | 1140 | } |
1135 | 1141 | } |
1136 | 1142 | |
1137 | | -} |
\ No newline at end of file |
| 1143 | +} |