then on the day he passes his property on to his sons, he must not treat the son of the loved wife as the firstborn in place of the son of the unloved wife, who is actually the firstborn.
In context
14But if you are not pleased with her, let her go wherever she wishes. You must not sell her for money or treat her as merchandise, because you have humiliated her. 15If a man has two wives, one loved and the other unloved, and both have borne him sons, and the firstborn belongs to the unloved wife, 16then on the day he passes his property on to his sons, he must not treat the son of the loved wife as the firstborn in place of the son of the unloved wife, who is actually the firstborn. 17He must acknowledge the firstborn, the son of the unloved wife, by giving him a double share of everything he has, since he is the first sign of his father’s strength; the right of the firstborn is his. 18If a man has a stubborn and rebellious son who will not obey his father or mother, and does not listen to them even after they discipline him,