Renamed and reorganized a bit