fix if bug, add beta for , while