The user role is a safe enough string, we may however pass it through the Html::cleanCssIdentifier

https://api.drupal.org/api/drupal/core%21lib%21Drupal%21Component%21Util...

Comments

skounis created an issue. See original summary.

  • 76276942 committed on 8.x-1.x
    Issue #3292164 - Sanitize body role classes and fix coding standards
    
dkmishra’s picture

Version: 8.x-1.2 » 8.x-1.5
Status: Active » Fixed

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

dkmishra’s picture

Status: Fixed » Closed (fixed)