fix plan mode