delete whitespaces before save