Merge pull request #3931 from libgit2/ethomson/checkout_dont_calculate_oid_for_dirs checkout: don't try to calculate oid for directories