cleanup some duplicate setup code