“Now when Joshua had sent the people away.” This is a summary statement; Joshua had already been recorded as having died.