Merge pull request #562 from jskda/align

Fixes to the align branch