implemented equals validation