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

4.x with PHP 7.x features #153

Merged
merged 4 commits into from Apr 30, 2022
Merged

4.x with PHP 7.x features #153

merged 4 commits into from Apr 30, 2022

Conversation

harikt
Copy link
Member

@harikt harikt commented Apr 4, 2022

No description provided.

@harikt harikt mentioned this pull request Apr 4, 2022
@@ -32,7 +34,7 @@ class Regex
* @return bool True if the value was sanitized, false if not.
*
*/
public function __invoke($subject, $field, $expr, $replace)
public function __invoke(object $subject, string $field, $expr, $replace): bool
Copy link
Member Author

Choose a reason for hiding this comment

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

I am wondering whether we need to remove is_scalar check and allow array also to be passed to $exp and $replace .

@harikt harikt changed the title WIP to use 7.x features 4.x with PHP 7.x features Apr 30, 2022
@harikt
Copy link
Member Author

harikt commented Apr 30, 2022

@koriym I am merging this. You can have a look into the PR. There are certain doubts / questions I have.

  1. Some of the tests are commented out for they fail due to wrong type value being passed.
  2. Eg : Validate\Max $max type can go for int | float I guess. Similar ones are there like Validate\Min . Do you think there can be other values other than that ?

We can discuss about the changes here.

Thank you

@harikt harikt merged commit 3e00cf6 into auraphp:4.x Apr 30, 2022
@harikt harikt mentioned this pull request Apr 30, 2022
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.

None yet

1 participant