Synced to last version from local clone

UTF-8 throughout the code
Started refactoring