fix #3483 (0 is a valid unit id)