fixed the word save function