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

Update translations #8

Open
wants to merge 9 commits into
base: 2.7.x
Choose a base branch
from
Open

Update translations #8

wants to merge 9 commits into from

Conversation

mpesari
Copy link

@mpesari mpesari commented Jan 22, 2020

Q A
Documentation no
Bugfix yes
BC Break maybe
New Feature no
RFC no
QA no

Description

This PR

  • Updates translation keys for the Upload and UploadFile validators from current https://github.com/laminas/laminas-validator/
  • Adds missing translation keys for the IsInt and Between validators
  • Adds and fixes several Finnish translations

@froschdesign froschdesign added the Bug Something isn't working label Jan 22, 2020
@froschdesign
Copy link
Member

froschdesign commented Jan 22, 2020

@mpesari
Thank you for your time and this contribution!

Some points that come to my mind:

  1. The support for the PSR-7 UploadedFileInterface was added with version 2.11.0 of the validator component. Therefore we must ensure that older versions of laminas-validator get the correct translations. This can be done with the conflict section of Composer.
  2. With the change of the English messages we also have to modify all translations. (I can translate the messages for German. For all other languages with need help – separate pull requests.)
  3. We need an unit test to check all message identifiers. See: Script is needed to check all message identifiers automatically #2

@froschdesign
Copy link
Member

Btw. we need another Finnish speaking person to reviewing it. (Two-man rule)

@froschdesign froschdesign added this to the 2.7.0 milestone Jan 22, 2020
@geerteltink geerteltink changed the base branch from master to 2.7.x September 11, 2020 13:04
// Laminas\Captcha\ReCaptcha
"Missing captcha fields" => "Captchan kenttiä puuttuu",
"Failed to validate captcha" => "Captchan tarkistus epäonnistui",
"Captcha value is wrong: %value%" => "Captchan arvo %value% on väärä",
Copy link
Member

Choose a reason for hiding this comment

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

The error message is wrong:

protected $messageTemplates = [
    self::MISSING_VALUE => 'Missing captcha fields',
    self::ERR_CAPTCHA   => 'Failed to validate captcha',
    self::BAD_CAPTCHA   => 'Captcha value is wrong',
];

https://github.com/laminas/laminas-captcha/blob/59173ecabf7602492345a39912874a9dafcacad1/src/ReCaptcha.php#L56-L60

@froschdesign froschdesign modified the milestones: 2.7.0, 2.6.2 Dec 10, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants