File tree Expand file tree Collapse file tree 6 files changed +14
-17
lines changed Expand file tree Collapse file tree 6 files changed +14
-17
lines changed Original file line number Diff line number Diff line change @@ -82,7 +82,7 @@ impl CatalystSignedDocument {
8282
8383 /// Return Document Type `UUIDv4`.
8484 ///
85- /// # Errros
85+ /// # Errors
8686 /// - Missing 'type' field.
8787 #[ must_use]
8888 pub fn doc_type ( & self ) -> anyhow:: Result < UuidV4 > {
@@ -91,7 +91,7 @@ impl CatalystSignedDocument {
9191
9292 /// Return Document ID `UUIDv7`.
9393 ///
94- /// # Errros
94+ /// # Errors
9595 /// - Missing 'id' field.
9696 #[ must_use]
9797 pub fn doc_id ( & self ) -> anyhow:: Result < UuidV7 > {
@@ -100,7 +100,7 @@ impl CatalystSignedDocument {
100100
101101 /// Return Document Version `UUIDv7`.
102102 ///
103- /// # Errros
103+ /// # Errors
104104 /// - Missing 'ver' field.
105105 #[ must_use]
106106 pub fn doc_ver ( & self ) -> anyhow:: Result < UuidV7 > {
@@ -115,7 +115,7 @@ impl CatalystSignedDocument {
115115
116116 /// Return document `ContentType`.
117117 ///
118- /// # Errros
118+ /// # Errors
119119 /// - Missing 'content-type' field.
120120 #[ must_use]
121121 pub fn doc_content_type ( & self ) -> anyhow:: Result < ContentType > {
@@ -171,7 +171,6 @@ impl CatalystSignedDocument {
171171
172172 /// Verify document signatures.
173173 /// Return true if all signatures are valid, otherwise return false.
174- /// Also it imediatly return false, if document is already invalid.
175174 ///
176175 ///
177176 /// # Errors
Original file line number Diff line number Diff line change @@ -62,7 +62,7 @@ pub struct Metadata {
6262impl Metadata {
6363 /// Return Document Cryptographic Algorithm
6464 ///
65- /// # Errros
65+ /// # Errors
6666 /// - Missing 'alg' field.
6767 #[ must_use]
6868 pub fn algorithm ( & self ) -> anyhow:: Result < Algorithm > {
@@ -71,7 +71,7 @@ impl Metadata {
7171
7272 /// Return Document Type `UUIDv4`.
7373 ///
74- /// # Errros
74+ /// # Errors
7575 /// - Missing 'type' field.
7676 #[ must_use]
7777 pub fn doc_type ( & self ) -> anyhow:: Result < UuidV4 > {
@@ -80,7 +80,7 @@ impl Metadata {
8080
8181 /// Return Document ID `UUIDv7`.
8282 ///
83- /// # Errros
83+ /// # Errors
8484 /// - Missing 'id' field.
8585 #[ must_use]
8686 pub fn doc_id ( & self ) -> anyhow:: Result < UuidV7 > {
@@ -89,7 +89,7 @@ impl Metadata {
8989
9090 /// Return Document Version `UUIDv7`.
9191 ///
92- /// # Errros
92+ /// # Errors
9393 /// - Missing 'ver' field.
9494 #[ must_use]
9595 pub fn doc_ver ( & self ) -> anyhow:: Result < UuidV7 > {
@@ -98,7 +98,7 @@ impl Metadata {
9898
9999 /// Returns the Document Content Type, if any.
100100 ///
101- /// # Errros
101+ /// # Errors
102102 /// - Missing 'content-type' field.
103103 #[ must_use]
104104 pub fn content_type ( & self ) -> anyhow:: Result < ContentType > {
Original file line number Diff line number Diff line change 1- //! Catalyst Signed Document `section` field type defition .
1+ //! Catalyst Signed Document `section` field type definition .
22
33use std:: { fmt:: Display , str:: FromStr } ;
44
55use coset:: cbor:: Value ;
66use serde:: { Deserialize , Serialize } ;
77
8- /// 'section' field type defition , which is a JSON path string
8+ /// 'section' field type definition , which is a JSON path string
99#[ derive( Clone , Debug , PartialEq ) ]
1010pub struct Section ( jsonpath_rust:: JsonPath < serde_json:: Value > ) ;
1111
Original file line number Diff line number Diff line change 1- //! Utitlity functions for metadata decoding fields
1+ //! Utility functions for metadata decoding fields
22
33use catalyst_types:: uuid:: CborContext ;
44use coset:: CborSerializable ;
Original file line number Diff line number Diff line change @@ -72,10 +72,8 @@ fn document_rules_init() -> HashMap<Uuid, Rules> {
7272 document_rules_map
7373}
7474
75- /// A comprehensive validation of the `CatalystSignedDocument`,
76- /// including a signature verification and document type based validation.
75+ /// A comprehensive document type based validation of the `CatalystSignedDocument`.
7776/// Return true if all signatures are valid, otherwise return false.
78- /// Also it imediatly return false, if document is already invalid.
7977///
8078/// # Errors
8179/// If `provider` returns error, fails fast throwing that error.
Original file line number Diff line number Diff line change @@ -27,7 +27,7 @@ pub(crate) struct Rules {
2727 pub ( crate ) content_type : ContentTypeRule ,
2828 /// 'content-encoding' field validation rule
2929 pub ( crate ) content_encoding : ContentEncodingRule ,
30- /// 'ref' field validation tule
30+ /// 'ref' field validation rule
3131 pub ( crate ) doc_ref : RefRule ,
3232 /// 'template' field validation rule
3333 pub ( crate ) template : TemplateRule ,
You can’t perform that action at this time.
0 commit comments