Closed vaurdan closed 1 month ago
[!IMPORTANT]
Review skipped
Auto reviews are disabled on base/target branches other than the default branch.
Base branches to auto review (4)
* develop * add/.* * fix/.* * update/.*Please check the settings in the CodeRabbit UI or the
.coderabbit.yaml
file in this repository. To trigger a single review, invoke the@coderabbitai review
command.You can disable this status message by setting the
reviews.review_status
tofalse
in the CodeRabbit configuration file.
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?
Description
In certain scenarios, it is possible for the API to return an empty set of Smart Links as suggestions. When this happens, the Smart Linking review modal does still open, and if there are no existing Smart Links on the content, it will be empty, as reported in #2626.
This PR adds an additional validation after processing the API smart links, and if there are none, it will prevent opening the modal, and will show an error (Snackbar and Notice) instead.
Motivation and context
How has this been tested?
Tested locally, by forcing the API to return an empty response.