It was 2 days, and they thought it was a different ship because they thought the Yorktown was sunk in the previous battle, not because they didn't think it could be repaired that fast (although that's probably also true).