Hi. First I'm new to the community so I'm not sure if Dev is the right tag to post. Please feel free to retag if I'm posting in the wrong place.
TLDR: what's the right way to arrange primary tags and secondary tags hierarchically? (for example, putting Extensibility, Internal, i18n, Theming under Dev)?
Details:
I arranged test tags structure like this:

I structured the tags this way because I figured I can nicely layout the tags in a nested display. But this way changes the position of secondary tags, which caused unexpected behavior:
The GlobalPolicy::can() method in the tags extension denies startDiscussion permission, when users have the global startDiscussion permission and all tags are non-restricted, because it's using tags.position=null to count primary/seconday tags.
why not use is_primary?
$primaryTagsWhereHasPermission = Tag::whereHasPermission($actor, $ability)
->where('tags.position', '!=', null)
->count();
$secondaryTagsWhereHasPermission = Tag::whereHasPermission($actor, $ability)
->where('tags.position', '=', null)
->count();
So, 1. how do I nest secondary tags under primary tags? (tried dragging in Admin but it aligns secondary with primary tags, but I would be doing it wrong)
- what's the right way of identify primary tag? position=null or is_primary=1?