fix notices being thrown