alm code fixes