update code and fix broken auth changes to firebase