Cockpit-HQ / Cockpit

Cockpit Core - Content Platform
https://getcockpit.com
Other
388 stars 47 forks source link

Old locale still appearing in API #89

Closed axeloz closed 1 year ago

axeloz commented 1 year ago

Hello,

When I first started cockpit, I created a "FR" locale. But I realized my mistake so I removed it and added a "EN" locale as my content will be in French first. But when I request the API without "locale" param, I still get :

    "title": "Ces métiers vont disparaître si nous ne transmettons pas le savoir-faire.",
    "title_fr": null,

If I'm not wrong, the title_fr should not appear. Instead, I should have a title_en. If I request the same API with "locale = en", I get:

    "title": "These jobs that will disappear if we don't transmit our know-how.",
    "title_fr": null,

Anything wrong? Thanks

axeloz commented 1 year ago

I cleared the models and started again and it works. It seems that locales changes are not working on existing models. Right?

aheinze commented 1 year ago

See my answer here: https://github.com/Cockpit-HQ/Cockpit/issues/91#issuecomment-1514549755