-
-
Notifications
You must be signed in to change notification settings - Fork 9.6k
[WIP][RFC][MessageCatalogue*] Add Metadata to MessageCatalogue. #4399
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
Conversation
} | ||
|
||
if (!is_string($domain)) { | ||
throw new \Exception("Domain should be an string."); |
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.
You're not consistent here. Below (294) you're throwing an InvalidArgumentException and here an Exception.
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.
Symfony never uses the base Exception class direclty. You should use the SPL exceptions
Reran latest php-cs-fixer. Used correct exceptions.
Tnx for the Exception feedback ... weird phpunit did not noticed the throwings. As this is a RFC what are your opinion about this change? |
@fabpot what do you think about this ? |
I'm ok with this new feature, but the implementation should be done without breaking BC. That's what I've done in #6349 |
This PR was merged into the master branch. Commits ------- 320fb6c [Translation] changed the MetadataAwareInterface method signatures 11ff433 [Translation] fixed CS in unit tests c40db35 [Translation] removed some code that is not done anywhere else in Symfony 63719a0 [Translation] created a new interface to avoid breaking BC 23e9e65 [Translation] fixed name 5607732 [Translation] added Metadata to MessageCatalogue Discussion ---------- [MessageCatalogue] Add Metadata to MessageCatalogue rework of #4399 For improving the Gettext tools (PO, MO File Loader/Dumper) we need at least storage for their meta data. This patch allows for issues below to store and process ie Po Header, Po Header Pluralisation rule. Open - [[WIP]: Allow Drupal to use Translate component](#4249) - [[2.1][Translator] Symfony translation process & gettext](#4245) Closed: - [[Translation] Po/MoFileLoader parse plurization rules](#3023) It has 1 TODO regarding addCatalogue: it now just override old values with new.
Commits ------- 3462afc Tests for PluralizationRules. Discussion ---------- [WIP][Translations][tests] Tests for PluralizationRules. Currently we have no tests PluralizationRules. This patch is an initial one to show we have not enough langcodes in PluralizationRules. I hope this gets in so others can fix the missing langcodes. I'm waiting for [RFC [MessageCatalogue*] Add Metadata to MessageCatalogue](symfony#4399) to get in to continue working on the [[WIP]: Allow Drupal to use Translate component](symfony#4249). --------------------------------------------------------------------------- by travisbot at 2012-05-25T14:38:37Z This pull request [passes](http://travis-ci.org/symfony/symfony/builds/1433558) (merged 3462afc into 023dbf8). --------------------------------------------------------------------------- by drak at 2012-07-01T09:47:05Z Is there anything pending in this PR?
Commits ------- 3462afc Tests for PluralizationRules. Discussion ---------- [WIP][Translations][tests] Tests for PluralizationRules. Currently we have no tests PluralizationRules. This patch is an initial one to show we have not enough langcodes in PluralizationRules. I hope this gets in so others can fix the missing langcodes. I'm waiting for [RFC [MessageCatalogue*] Add Metadata to MessageCatalogue](symfony/symfony#4399) to get in to continue working on the [[WIP]: Allow Drupal to use Translate component](symfony/symfony#4249). --------------------------------------------------------------------------- by travisbot at 2012-05-25T14:38:37Z This pull request [passes](http://travis-ci.org/symfony/symfony/builds/1433558) (merged 3462afc0 into 023dbf80). --------------------------------------------------------------------------- by drak at 2012-07-01T09:47:05Z Is there anything pending in this PR?
For improving the Gettext tools (PO, MO File Loader/Dumper) we need at least storage for their meta data.
This patch allows for issues below to store and process ie Po Header, Po Header Pluralisation rule.
Open
Closed:
It has 1 TODO regarding addCatalogue: it now just override old values with new.