For CPT’s I have one which is a plural name ‘documents’ as it’s a library of multiple documents per post. In WPFront this is showing up in permissions with a double ss.
Example of the double ss’s;
publish_documentss edit_documentss delete_documentss edit_published_documentss delete_published_documentss edit_others_documentss delete_others_documentss read_private_documentss edit_private_documentss delete_private_documentss
*Not sure if would be easy to do a check for ending s and not double it up.
In WordPress standards, CPT names are ‘singular’. So that’s why the role capabilities come with ‘plural’ names.
If we were to not use the plural name for role capability, then it will create a conflict. Because under the hood, both singular and plural capabilities exists. For example if you have a CPT called ‘ABC’, then both ‘edit_abc’ and ‘edit_abcs’ exist in the system. If we were to ignore the ‘s’ because ‘ABC’ itself is plural, then it will conflict between singular and plural capabilities.
Not only that I don’t think checking for an ‘s’ at the end is always going to satisfy the condition.(Ex: address)