Remove an unnecessary condition from Ukrainian grammar rules
[lhc/web/wiklou.git] / resources / src / mediawiki.language / languages / uk.js
index f331443..138045c 100644 (file)
@@ -9,27 +9,24 @@ mediaWiki.language.convertGrammar = function ( word, form ) {
        }
        switch ( form ) {
                case 'genitive': // родовий відмінок
-                       if ( word.slice( -4 ) !== 'вікі' && word.slice( -4 ) !== 'Вікі' ) {
-                               if ( word.slice( -2 ) === 'ія' ) {
-                                       word = word.slice( 0, -2 ) + 'ії';
-                               } else if ( word.slice( -2 ) === 'ка' ) {
-                                       word = word.slice( 0, -2 ) + 'ки';
-                               } else if ( word.slice( -2 ) === 'ти' ) {
-                                       word = word.slice( 0, -2 ) + 'т';
-                               } else if ( word.slice( -2 ) === 'ди' ) {
-                                       word = word.slice( 0, -2 ) + 'дів';
-                               } else if ( word.slice( -3 ) === 'ник' ) {
-                                       word = word.slice( 0, -3 ) + 'ника';
-                               }
+                       if ( word.slice( -2 ) === 'ія' ) {
+                               word = word.slice( 0, -2 ) + 'ії';
+                       } else if ( word.slice( -2 ) === 'ти' ) {
+                               word = word.slice( 0, -2 ) + 'т';
+                       } else if ( word.slice( -2 ) === 'ди' ) {
+                               word = word.slice( 0, -2 ) + 'дів';
+                       } else if ( word.slice( -3 ) === 'ник' ) {
+                               word = word.slice( 0, -3 ) + 'ника';
                        }
+
                        break;
                case 'accusative': // знахідний відмінок
-                       if ( word.slice( -4 ) !== 'вікі' && word.slice( -4 ) !== 'Вікі' ) {
-                               if ( word.slice( -2 ) === 'ія' ) {
-                                       word = word.slice( 0, -2 ) + 'ію';
-                               }
+                       if ( word.slice( -2 ) === 'ія' ) {
+                               word = word.slice( 0, -2 ) + 'ію';
                        }
+
                        break;
        }
+
        return word;
 };