Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Compute guid on .toString() version of the message. #149

Conversation

louim
Copy link
Contributor

@louim louim commented Mar 3, 2016

Hello!

This PR allows using Ember i18n service, or any string which is an Ember SafeString and have the { preventDuplicates: true } work by computing the guid value on the stringified version of the message. Before, it computed the guid directly, so two different instance of the same objet would get different guid. I added a test to cover the case.

Note: there is a test failing, but it was failing before too.

This allows using Ember i18n service, or any string which is an Ember SafeString
and have the `{ preventDuplicates: true }` option work as expected.
@poteto
Copy link
Collaborator

poteto commented Mar 3, 2016

LGTM, thanks!

@homu r+

@homu
Copy link
Contributor

homu commented Mar 3, 2016

📌 Commit 9bdcd4d has been approved by poteto

@homu homu merged commit 9bdcd4d into adopted-ember-addons:master Mar 3, 2016
@homu
Copy link
Contributor

homu commented Mar 3, 2016

⚡ Test exempted - status

homu added a commit that referenced this pull request Mar 3, 2016
…poteto

Compute guid on .toString() version of the message.

Hello!

This PR allows using Ember i18n service, or any string which is an Ember SafeString and have the `{ preventDuplicates: true }` work by computing the guid value on the stringified version of the message. Before, it computed the guid directly, so two different instance of the same objet would get different guid. I added a test to cover the case.

Note: there is a test failing, but it was failing before too.
@louim louim deleted the feature/same-guid-for-object-message branch March 3, 2016 22:04
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants