Work on phire refactor