mirror of
https://github.com/ipfs/kubo.git
synced 2025-06-26 23:53:19 +08:00
fix error when encountering a sharded directory when expecting a file
License: MIT Signed-off-by: Steven Allen <steven@stebalien.com>
This commit is contained in:
@ -112,7 +112,7 @@ func (dr *PBDagReader) precalcNextBuf(ctx context.Context) error {
|
|||||||
}
|
}
|
||||||
|
|
||||||
switch pb.GetType() {
|
switch pb.GetType() {
|
||||||
case ftpb.Data_Directory:
|
case ftpb.Data_Directory, ftpb.Data_HAMTShard:
|
||||||
// A directory should not exist within a file
|
// A directory should not exist within a file
|
||||||
return ft.ErrInvalidDirLocation
|
return ft.ErrInvalidDirLocation
|
||||||
case ftpb.Data_File:
|
case ftpb.Data_File:
|
||||||
|
Reference in New Issue
Block a user