In administrator/components/com_content/tmpl/articles/default.php, $canCreate permission is not used at all, so no need to calculate it for each article
In other controller classes, no need for define and and use $allow variable. The logic for checking add permission is simple: If Category ID is passed, check add permission of the category, otherwise, fallback to component permissio
LGTM! Thankyou :)