String cleanup. Hopefully fixes pick_quality issue too