Better handling of document changes that update refactoring

https://github.com/MiguelCastillo/Brackets-Ternific/issues/30
Bumping version to 0.5.2