CRM-13920 fix case count and activity creation perm check