Another fix for part of #99
Merge branch 'dev' into ms