Really too much duplicated code now