added dup check