fixing a notice in error log