King James Version
In any case thou shalt deliver him the pledge again when the sun goeth down, that he may sleep in his own raiment, and bless thee: and it shall be righteousness unto thee before the LORD thy God.English Standard Version
You shall restore to him the pledge as the sun sets, that he may sleep in his cloak and bless you. And it shall be righteousness for you before the LORD your God.New International Version
Return his cloak to him by sunset so that he may sleep in it. Then he will thank you, and it will be regarded as a righteous act in the sight of the LORD your God.