I will move this logic to SonataFormatterExtension and check for the existence of richhtml.