Fatal error bug fix due to non-existing directories (using PHP5.3 exceptions)