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
Forms: convert value to string after it is translated #1098
Conversation
Nette/Forms/Controls/SelectBox.php
Outdated
@@ -201,7 +201,7 @@ public function getControl() | |||
if ($this->prompt !== FALSE) { | |||
$control->add($this->prompt instanceof Nette\Utils\Html | |||
? $this->prompt->value('') | |||
: (string) $option->value('')->setText($this->translate((string) $this->prompt)) | |||
: (string) $option->value('')->setText((string) $this->translate($this->prompt)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the inner type cast should be still there.
👎 |
The point here was to remove the typecast before passing the value to translator. This should be also modified in |
„Forms: convert value to string after it is translated“? I am missing the point… |
I was talking with @achtan on skype... The point here is only to remove the |
Well, |
@hosiplan and why? |
|
991ba1a
to
e23de7a
Compare
489cca2
to
0b969cd
Compare
09a7d92
to
b9698a8
Compare
5a8c108
to
3aa3147
Compare
5feee0e
to
3fc1e40
Compare
No description provided.