update gems and remove old code