How to get current locale in lifecycles?

System Information
  • Strapi Version: 3.6.2
  • Operating System: macOS
  • Database: SQLite
  • Node Version:
  • NPM Version:
  • Yarn Version:

Hello, I want to sync some fields between different locales, for example product prices. I want to firstly get the locale of the current entry, then use the rest of locales to query the corresponding translated entries.

data.locale seems work

Currently the workaround for me is to create an en entity, automatically fill some non translatable fields with lifecycles(only in en locale), change to the other locale, click the fill from other locales button, then change the fields which need translations, doing some conversions inside beforeCreate lifecycle, save the entity.