Update header.php

Fixed an exception being thrown where no pages were found.