seperate the implementation a bit, things are wonky