firebase integration / lots of changes