Index: trunk/phase3/includes/installer/WebInstallerOutput.php |
— | — | @@ -144,11 +144,7 @@ |
145 | 145 | */ |
146 | 146 | public function getDir() { |
147 | 147 | global $wgLang; |
148 | | - if( !is_object( $wgLang ) || !$wgLang->isRtl() ) { |
149 | | - return 'ltr'; |
150 | | - } else { |
151 | | - return 'rtl'; |
152 | | - } |
| 148 | + return is_object( $wgLang ) ? $wgLang->getDir() : 'ltr'; |
153 | 149 | } |
154 | 150 | |
155 | 151 | /** |
— | — | @@ -156,11 +152,7 @@ |
157 | 153 | */ |
158 | 154 | public function getLanguageCode() { |
159 | 155 | global $wgLang; |
160 | | - if( !is_object( $wgLang ) ) { |
161 | | - return 'en'; |
162 | | - } else { |
163 | | - return $wgLang->getCode(); |
164 | | - } |
| 156 | + return is_object( $wgLang ) ? $wgLang->getCode() : 'en'; |
165 | 157 | } |
166 | 158 | |
167 | 159 | /** |