Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add couple of array value #45

Conversation

Umangvaghela
Copy link

add couple of array value

@@ -902,16 +902,19 @@ private function pluralize( $word ) {
'/$/' => 's'
);

$uncountable = array( 'equipment', 'information', 'rice', 'money', 'species', 'series', 'fish', 'sheep' );

$uncountable = array('sheep', 'fish','deer','series','species','money','rice','information','equipment');
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Umangvaghela While you're working on this, can you please update this as per WordPress' coding standards?

  1. Space after ,
  2. Space after ( and before )

More details about coding standards can be found here -
https://make.wordpress.org/core/handbook/best-practices/coding-standards/php/

'man' => 'men',
'tooth' => 'teeth',
'person' => 'people',
'valve' => 'valves'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Last array item must end with a ,

@Umangvaghela
Copy link
Author

Hi @Sidsector9

I have added a patch to remove white space issue to use PHP editor.

@miya0001
Copy link
Member

Hi @Umangvaghela

Thanks for PR!

Can you recover the sort order of elements?
Please add new element at the last if you want to add.

We have to check every element. 😓

@miya0001 miya0001 self-requested a review August 23, 2017 12:23
@@ -902,15 +902,18 @@ private function pluralize( $word ) {
'/$/' => 's'
);

$uncountable = array( 'equipment', 'information', 'rice', 'money', 'species', 'series', 'fish', 'sheep' );
$uncountable = array( 'sheep', 'fish', 'deer', 'series', 'species', 'money', 'rice', 'information', 'equipment' );
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please recover sort order of the elements.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@miya0001
$uncountable = array( 'sheep', 'fish', 'deer', 'series', 'species', 'money', 'rice', 'information', 'equipment' );
do you want this form
$uncountable = array( 'deer','equipment', 'fish' , 'information', 'money', 'rice', 'series', 'sheep', 'species' );

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Umangvaghela what @miya0001 meant is that don't change the order of the default array. If you want to add new elements then add it to the end of the array.


$irregular = array(
'person' => 'people',
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please recover sort order of the elements.

@miya0001
Copy link
Member

Anyway, is this pattern is finite?
Do you know any dictionary or so?

@miya0001
Copy link
Member

It is same problem with #42, #44.
Please see discussion on the #44

@miya0001
Copy link
Member

miya0001 commented Aug 23, 2017

@Umangvaghela

Oh, I apologize for lack of explanation in this topic.
I wrote a reason why I close this PR at #44 , so I forgot to say thank you in this topic.

Actually, we are really appreciate you, but I want to find the best way to solve the problem.
So, I already open a new issue which is found out by your effort.
#48

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants