This repository was archived by the owner on Feb 5, 2026. It is now read-only.
File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -49,25 +49,19 @@ func (protonDrive *ProtonDrive) GetActiveRevisionAttrs(ctx context.Context, link
4949 return nil , ErrLinkMustNotBeNil
5050 }
5151
52- revisionsMetadata , err := protonDrive .GetRevisions (ctx , link , proton .RevisionStateActive )
53- if err != nil {
54- return nil , err
55- }
56-
57- if len (revisionsMetadata ) != 1 {
58- return nil , ErrCantFindActiveRevision
59- }
52+ revisionMetadata := link .FileProperties .ActiveRevision
53+ revisionMetadata .XAttr = link .XAttr
6054
6155 nodeKR , err := protonDrive .getLinkKR (ctx , link )
6256 if err != nil {
6357 return nil , err
6458 }
6559
66- signatureVerificationKR , err := protonDrive .getSignatureVerificationKeyring ([]string {link . FileProperties . ActiveRevision .SignatureEmail })
60+ signatureVerificationKR , err := protonDrive .getSignatureVerificationKeyring ([]string {revisionMetadata .SignatureEmail })
6761 if err != nil {
6862 return nil , err
6963 }
70- revisionXAttrCommon , err := revisionsMetadata [ 0 ] .GetDecXAttrString (signatureVerificationKR , nodeKR )
64+ revisionXAttrCommon , err := revisionMetadata .GetDecXAttrString (signatureVerificationKR , nodeKR )
7165 if err != nil {
7266 return nil , err
7367 }
You can’t perform that action at this time.
0 commit comments