refactoring
fix for win8