fixing firebase exception issue
removing unnecessary check