So he left them with the king of Moab. And they stayed with the king as long as David was hiding in the protected place.