some fixs due to update for foundation 5