Index: trunk/extensions/SemanticResultFormats/SemanticResultFormats.php |
— | — | @@ -125,25 +125,23 @@ |
126 | 126 | 'tagcloud' => array( 'tag cloud' ) |
127 | 127 | ); |
128 | 128 | |
129 | | - // Register the resource loader modules for when they are supported. |
130 | | - if ( defined( 'MW_SUPPORTS_RESOURCE_MODULES' ) ) { |
131 | | - foreach ( $srfgFormats as $format ) { |
132 | | - if ( array_key_exists( $format, $formatClasses ) ) { |
133 | | - $smwgResultFormats[$format] = $formatClasses[$format]; |
134 | | - |
135 | | - if ( method_exists( $formatClasses[$format], 'registerResourceModules' ) ) { |
136 | | - call_user_func( array( $formatClasses[$format], 'registerResourceModules' ) ); |
137 | | - } |
138 | | - |
139 | | - if ( isset( $smwgResultAliases ) && array_key_exists( $format, $formatAliases ) ) { |
140 | | - $smwgResultAliases[$format] = $formatAliases[$format]; |
141 | | - } |
| 129 | + foreach ( $srfgFormats as $format ) { |
| 130 | + if ( array_key_exists( $format, $formatClasses ) ) { |
| 131 | + $smwgResultFormats[$format] = $formatClasses[$format]; |
| 132 | + |
| 133 | + // Register the resource loader modules for when they are supported. |
| 134 | + if ( defined( 'MW_SUPPORTS_RESOURCE_MODULES' ) && method_exists( $formatClasses[$format], 'registerResourceModules' ) ) { |
| 135 | + call_user_func( array( $formatClasses[$format], 'registerResourceModules' ) ); |
142 | 136 | } |
143 | | - else { |
144 | | - wfDebug( "There is not result format class associated with the format '$format'." ); |
| 137 | + |
| 138 | + if ( isset( $smwgResultAliases ) && array_key_exists( $format, $formatAliases ) ) { |
| 139 | + $smwgResultAliases[$format] = $formatAliases[$format]; |
145 | 140 | } |
146 | | - } |
147 | | - } |
| 141 | + } |
| 142 | + else { |
| 143 | + wfDebug( "There is not result format class associated with the format '$format'." ); |
| 144 | + } |
| 145 | + } |
148 | 146 | } |
149 | 147 | |
150 | 148 | /** |