added duplicate registration functionality, all tests passed