Fixed swap method that wasn't actually swapping