fixed leave from view error