redid this whole mess