fixed uniqqueness bug