changed null to default, this is more robust.