fix for never-ending pan