Refactor properties parsing