basalt / drives-dropbox/src / toDriveItem
Function: toDriveItem()
> toDriveItem(entry): DriveItem
Defined in: drives-dropbox/src/metadata.ts:47
Maps one entry.
Three decisions worth stating, because each is a place a vendor difference could have been flattened:
versionisrev, not a timestamp. Dropbox'srevchanges when, and only when, the content changes;server_modifiedalso moves on a move or a re-share. The dedup ledger prefersversion, so a rename costs nothing.checksumis labelleddropboxContentHash, notsha256. It is a block-tree digest (seecontent-hash.ts) and is not comparable with another provider's SHA-256 of the same bytes. Labelling it honestly is what stops an app from concluding two files differ because two vendors hash differently.contentTypeis absent. Dropbox reports no media type at all, which is the contract's best case rather than its worst:contentTypeis documented as untrusted, and@basaltkit/filessniffs the bytes regardless.