updated with firebase