Modules
Additional Perl::Critic policies.
Write lc($x // "Default") instead of lc $x // "Default".
Use subroutines instead of inline do-blocks.
Write is_arrayref($var) instead of ref($var) eq 'ARRAY'.
Use named loop control variables.