Fix goal completion detection