Skip to content

Commit feb8332

Browse files
committed
Use correct pluralization for octopus and virus
1 parent 8a726b1 commit feb8332

2 files changed

Lines changed: 13 additions & 13 deletions

File tree

lib/inflection.js

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -367,7 +367,7 @@
367367
oes : new RegExp( '(o)es$' , 'gi' ),
368368
shoes : new RegExp( '(shoe)s$' , 'gi' ),
369369
crises : new RegExp( '(cris|ax|test)es$' , 'gi' ),
370-
octopi : new RegExp( '(octop|vir)i$' , 'gi' ),
370+
octopuses : new RegExp( '(octop|vir)uses$' , 'gi' ),
371371
aliases : new RegExp( '(alias|canvas|status|campus)es$', 'gi' ),
372372
summonses : new RegExp( '^(summons)es$' , 'gi' ),
373373
oxen : new RegExp( '^(ox)en' , 'gi' ),
@@ -437,7 +437,7 @@
437437
[ regex.plural.oes ],
438438
[ regex.plural.shoes ],
439439
[ regex.plural.crises ],
440-
[ regex.plural.octopi ],
440+
[ regex.plural.octopuses ],
441441
[ regex.plural.aliases ],
442442
[ regex.plural.summonses ],
443443
[ regex.plural.oxen ],
@@ -456,7 +456,7 @@
456456
[ regex.singular.child , '$1ren' ],
457457
[ regex.singular.ox , '$1en' ],
458458
[ regex.singular.axis , '$1es' ],
459-
[ regex.singular.octopus , '$1i' ],
459+
[ regex.singular.octopus , '$1uses' ],
460460
[ regex.singular.alias , '$1es' ],
461461
[ regex.singular.summons , '$1es' ],
462462
[ regex.singular.bus , '$1ses' ],
@@ -537,7 +537,7 @@
537537
[ regex.plural.oes , '$1' ],
538538
[ regex.plural.shoes , '$1' ],
539539
[ regex.plural.crises , '$1is' ],
540-
[ regex.plural.octopi , '$1us' ],
540+
[ regex.plural.octopuses, '$1us' ],
541541
[ regex.plural.aliases , '$1' ],
542542
[ regex.plural.summonses, '$1' ],
543543
[ regex.plural.oxen , '$1' ],
@@ -662,7 +662,7 @@
662662
* var inflection = require( 'inflection' );
663663
*
664664
* inflection.pluralize( 'person' ); // === 'people'
665-
* inflection.pluralize( 'octopus' ); // === 'octopi'
665+
* inflection.pluralize( 'octopus' ); // === 'octopuses'
666666
* inflection.pluralize( 'Hat' ); // === 'Hats'
667667
* inflection.pluralize( 'person', 'guys' ); // === 'guys'
668668
*/
@@ -684,7 +684,7 @@
684684
* var inflection = require( 'inflection' );
685685
*
686686
* inflection.singularize( 'people' ); // === 'person'
687-
* inflection.singularize( 'octopi' ); // === 'octopus'
687+
* inflection.singularize( 'octopuses' ); // === 'octopus'
688688
* inflection.singularize( 'Hats' ); // === 'Hat'
689689
* inflection.singularize( 'guys', 'person' ); // === 'person'
690690
*/
@@ -707,11 +707,11 @@
707707
* var inflection = require( 'inflection' );
708708
*
709709
* inflection.inflect( 'people' 1 ); // === 'person'
710-
* inflection.inflect( 'octopi' 1 ); // === 'octopus'
710+
* inflection.inflect( 'octopuses' 1 ); // === 'octopus'
711711
* inflection.inflect( 'Hats' 1 ); // === 'Hat'
712712
* inflection.inflect( 'guys', 1 , 'person' ); // === 'person'
713713
* inflection.inflect( 'person', 2 ); // === 'people'
714-
* inflection.inflect( 'octopus', 2 ); // === 'octopi'
714+
* inflection.inflect( 'octopus', 2 ); // === 'octopuses'
715715
* inflection.inflect( 'Hat', 2 ); // === 'Hats'
716716
* inflection.inflect( 'person', 2, null, 'guys' ); // === 'guys'
717717
*/

test/inflection.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ describe( 'test .pluralize', function (){
2121
inflection.pluralize( 'women' ).should.equal( 'women' );
2222
inflection.pluralize( 'woman' ).should.equal( 'women' );
2323
inflection.pluralize( 'person' ).should.equal( 'people' );
24-
inflection.pluralize( 'octopus' ).should.equal( 'octopi' );
24+
inflection.pluralize( 'octopus' ).should.equal( 'octopuses' );
2525
inflection.pluralize( 'human' ).should.equal( 'humans' );
2626
inflection.pluralize( 'aircraft' ).should.equal( 'aircraft' );
2727
inflection.pluralize( 'luck' ).should.equal( 'luck' );
@@ -71,7 +71,7 @@ describe( 'test .singularize', function (){
7171
inflection.singularize( 'people' ).should.equal( 'person' );
7272
inflection.singularize( 'movies' ).should.equal( 'movie' );
7373
inflection.singularize( 'queries' ).should.equal( 'query' );
74-
inflection.singularize( 'octopi' ).should.equal( 'octopus' );
74+
inflection.singularize( 'octopuses' ).should.equal( 'octopus' );
7575
inflection.singularize( 'Hats' ).should.equal( 'Hat' );
7676
inflection.singularize( 'lives' ).should.equal( 'life' );
7777
inflection.singularize( 'baths' ).should.equal( 'bath' );
@@ -111,7 +111,7 @@ describe( 'test .inflect', function (){
111111
inflection.inflect( 'people', 0 ).should.equal( 'people' );
112112
inflection.inflect( 'men', 0 ).should.equal( 'men' );
113113
inflection.inflect( 'person', 0 ).should.equal( 'people' );
114-
inflection.inflect( 'octopus', 0 ).should.equal( 'octopi' );
114+
inflection.inflect( 'octopus', 0 ).should.equal( 'octopuses' );
115115
inflection.inflect( 'Hat', 0 ).should.equal( 'Hats' );
116116
inflection.inflect( 'data', 0 ).should.equal( 'data' );
117117
inflection.inflect( 'meta', 0 ).should.equal( 'meta' );
@@ -120,7 +120,7 @@ describe( 'test .inflect', function (){
120120
inflection.inflect( 'people', 2 ).should.equal( 'people' );
121121
inflection.inflect( 'men', 2 ).should.equal( 'men' );
122122
inflection.inflect( 'person', 2 ).should.equal( 'people' );
123-
inflection.inflect( 'octopus', 2 ).should.equal( 'octopi' );
123+
inflection.inflect( 'octopus', 2 ).should.equal( 'octopuses' );
124124
inflection.inflect( 'Hat', 2 ).should.equal( 'Hats' );
125125
inflection.inflect( 'data', 2 ).should.equal( 'data' );
126126
inflection.inflect( 'meta', 2 ).should.equal( 'meta' );
@@ -134,7 +134,7 @@ describe( 'test .inflect', function (){
134134
inflection.inflect( 'people', 1 ).should.equal( 'person' );
135135
inflection.inflect( 'movies', 1 ).should.equal( 'movie' );
136136
inflection.inflect( 'queries', 1 ).should.equal( 'query' );
137-
inflection.inflect( 'octopi', 1 ).should.equal( 'octopus' );
137+
inflection.inflect( 'octopuses', 1 ).should.equal( 'octopus' );
138138
inflection.inflect( 'Hats', 1 ).should.equal( 'Hat' );
139139
inflection.inflect( 'data', 1 ).should.equal( 'datum' );
140140
inflection.inflect( 'meta', 1 ).should.equal( 'metum' );

0 commit comments

Comments
 (0)