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 new validator #562

Merged
merged 9 commits into from
Sep 15, 2020
Merged

add new validator #562

merged 9 commits into from
Sep 15, 2020

Conversation

nadar
Copy link
Member

@nadar nadar commented Sep 15, 2020

New i18n attribute required validator.

*/
class I18nRequiredValidator extends Validator
{
public function validateAttribute($model, $attribute)
Copy link

Choose a reason for hiding this comment

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

Function validateAttribute has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.

@codeclimate
Copy link

codeclimate bot commented Sep 15, 2020

Code Climate has analyzed commit 9635ffa and detected 16 issues on this pull request.

Here's the issue category breakdown:

Category Count
Complexity 1
Duplication 15

The test coverage on the diff in this pull request is 100.0% (50% is the threshold).

This pull request will bring the total coverage in the repository to 48.4% (0.0% change).

View more on Code Climate.

@nadar nadar merged commit 1d5faa8 into master Sep 15, 2020
@nadar nadar deleted the i18n-required-validator branch September 15, 2020 14:21
slowfox089 pushed a commit to slowfox089/luya-module-admin that referenced this pull request Dec 10, 2020
* add new validator

* add tests

* add tests

* de language key

* update docs

* Text updates

* German translation

* add missing translation files

* add changelog

Co-authored-by: Roland Schaub <roland.schaub@zephir.ch>
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.

2 participants