remove deprecatedd swap method