fixed a php notice for undefined variable