fix(plugin-seo): return empty if localized fields are only seo #30
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This is not how this should be done.
It is an interim fix while I figure out how to handle a scenario where there are no localized fields on a collection except the localized fields added by https://github.com/payloadcms/plugin-seo.
By default,
payload-crowdin-sync
detects localized fields on a collection or global, and then syncs with crowdIn automatically. If SEO is enabled on a collection or global without localized fields, it will start syncing with crowdIn for the meta fields only.This makes the following scenario likely: #29.
To keep this default behaviour, I am implementing this measure. This should be removed once #29 is resolved because only localized SEO fields is a reasonable scenario (e.g. a gallery of images or a collection that contains fields unsupported by the plugin).