Replaced short ternary operator, because it does not work in PHP 5.2