How to remove locale in globalize?

427 views Asked by At

I'm using globalize/globalize to add model translations.
I have ru, en locales and want to remove en locale from object, how can I remove?

Tried to remove in such a way, but it removes all object with ru, en locales.

Country.with_translations(:en).find(1).destroy
1

There are 1 answers

0
Danil Speransky On BEST ANSWER

Try this:

country.translations.find_by(locale: :en).destroy