Fixed addNewURLtoRepository() by adding the delete statement