fix map behaviour