Hello. In general, there is nothing complicated. We check what has come, soap or phone and accordingly we are trying to deliver an email or phone from the database, to check for the existence of a password.
But I do not want to write govnokod)). How best to organize data verification and query from the database? I would be grateful for advice and assistance.