diff --git a/anoncreds/src/data_types/anoncreds/rev_reg_def.rs b/anoncreds/src/data_types/anoncreds/rev_reg_def.rs index 39434453..7a935aac 100644 --- a/anoncreds/src/data_types/anoncreds/rev_reg_def.rs +++ b/anoncreds/src/data_types/anoncreds/rev_reg_def.rs @@ -39,7 +39,6 @@ impl IssuanceType { *self == IssuanceType::ISSUANCE_BY_DEFAULT } } - #[allow(non_camel_case_types)] #[derive(Copy, Clone, Debug, PartialEq, Eq, Deserialize, Serialize)] pub enum RegistryType { diff --git a/anoncreds/src/data_types/anoncreds/schema.rs b/anoncreds/src/data_types/anoncreds/schema.rs index 133f5019..24f68e6a 100644 --- a/anoncreds/src/data_types/anoncreds/schema.rs +++ b/anoncreds/src/data_types/anoncreds/schema.rs @@ -22,7 +22,6 @@ pub struct SchemaV1 { pub version: String, #[serde(rename = "attrNames")] pub attr_names: AttributeNames, - pub seq_no: Option, } #[derive(Debug, Clone, Serialize, Deserialize, Default)] diff --git a/anoncreds/src/ffi/schema.rs b/anoncreds/src/ffi/schema.rs index 26718564..a5482c3e 100644 --- a/anoncreds/src/ffi/schema.rs +++ b/anoncreds/src/ffi/schema.rs @@ -10,7 +10,6 @@ pub extern "C" fn anoncreds_create_schema( schema_name: FfiStr, schema_version: FfiStr, attr_names: FfiStrList, - seq_no: i64, result_p: *mut ObjectHandle, ) -> ErrorCode { catch_error(|| { @@ -25,11 +24,6 @@ pub extern "C" fn anoncreds_create_schema( schema_name, schema_version, attr_names.to_string_vec()?.into(), - if seq_no > 0 { - Some(seq_no as u32) - } else { - None - }, )?; let handle = ObjectHandle::create(schema)?; unsafe { *result_p = handle }; diff --git a/anoncreds/src/services/issuer.rs b/anoncreds/src/services/issuer.rs index 725abe6d..eed81d38 100644 --- a/anoncreds/src/services/issuer.rs +++ b/anoncreds/src/services/issuer.rs @@ -30,7 +30,6 @@ pub fn create_schema( schema_name: &str, schema_version: &str, attr_names: AttributeNames, - seq_no: Option, ) -> Result { trace!( "create_schema >>> schema_name: {:?}, schema_version: {:?}, attr_names: {:?}", @@ -43,7 +42,6 @@ pub fn create_schema( name: schema_name.to_string(), version: schema_version.to_string(), attr_names, - seq_no, }; Ok(Schema::SchemaV1(schema)) } diff --git a/anoncreds/tests/anoncreds_demos.rs b/anoncreds/tests/anoncreds_demos.rs index 0816794f..d1bbdce9 100644 --- a/anoncreds/tests/anoncreds_demos.rs +++ b/anoncreds/tests/anoncreds_demos.rs @@ -13,10 +13,10 @@ use self::utils::anoncreds::{IssuerWallet, ProverWallet}; mod utils; -pub static GVT_SCHEMA_NAME: &'static str = "gvt"; -pub static GVT_SCHEMA_ATTRIBUTES: &[&'static str; 4] = &["name", "age", "sex", "height"]; pub static SCHEMA_ID: &str = "mock:uri"; pub static CRED_DEF_ID: &str = "mock:uri"; +pub const GVT_SCHEMA_NAME: &str = "gvt"; +pub const GVT_SCHEMA_ATTRIBUTES: &[&str; 4] = &["name", "age", "sex", "height"]; #[test] fn anoncreds_works_for_single_issuer_single_prover() { @@ -27,13 +27,9 @@ fn anoncreds_works_for_single_issuer_single_prover() { let mut prover_wallet = ProverWallet::default(); // Issuer creates Schema - would be published to the ledger - let gvt_schema = issuer::create_schema( - GVT_SCHEMA_NAME, - "1.0", - GVT_SCHEMA_ATTRIBUTES[..].into(), - None, - ) - .expect("Error creating gvt schema for issuer"); + let gvt_schema = + issuer::create_schema(GVT_SCHEMA_NAME, "1.0", GVT_SCHEMA_ATTRIBUTES[..].into()) + .expect("Error creating gvt schema for issuer"); // Issuer creates Credential Definition let cred_def_parts = issuer::create_credential_definition(