fixed windows problem (saveContent), small refactoring