Implemented method to check firebase authentication