removed some of phi'ls stuff, added some of my own