[ticket/12675] Fix code sniffer complaints introduced by recent commits

Issues fixed described in ticket.

Ticket: https://tracker.phpbb.com/browse/PHPBB3-12675