Add support for StatusList2021 #4208
Annotations
5 errors and 1 warning
mismatched types:
src/credential/revocation/status_list_2021/credential.rs#L121
error[E0308]: mismatched types
--> src/credential/revocation/status_list_2021/credential.rs:121:5
|
120 | pub fn entry(&self, index: usize) -> Result<Option<bool>> {
| -------------------- expected `std::result::Result<std::option::Option<bool>, wasm_bindgen::JsValue>` because of return type
121 | / self
122 | | .inner
123 | | .entry(index)
124 | | .map_err(|e| JsValue::from(JsError::new(&e.to_string())))
| |_______________________________________________________________^ expected `Result<Option<bool>, JsValue>`, found `Result<bool, JsValue>`
|
= note: expected enum `std::result::Result<std::option::Option<bool>, _>`
found enum `std::result::Result<bool, _>`
|
no method named `update_status_list` found for struct `identity_iota::credential::status_list_2021::StatusList2021Credential` in the current scope:
src/credential/revocation/status_list_2021/credential.rs#L132
error[E0599]: no method named `update_status_list` found for struct `identity_iota::credential::status_list_2021::StatusList2021Credential` in the current scope
--> src/credential/revocation/status_list_2021/credential.rs:132:8
|
130 | / self
131 | | .inner
132 | | .update_status_list(|list| list.set(index, state))
| | -^^^^^^^^^^^^^^^^^^ method not found in `StatusList2021Credential`
| |_______|
|
|
mismatched types:
src/credential/revocation/status_list_2021/status_list.rs#L36
error[E0308]: mismatched types
--> src/credential/revocation/status_list_2021/status_list.rs:36:5
|
35 | pub fn get(&self, index: usize) -> Option<bool> {
| ------------ expected `std::option::Option<bool>` because of return type
36 | self.0.get(index)
| ^^^^^^^^^^^^^^^^^ expected `Option<bool>`, found `Result<bool, StatusListError>`
|
= note: expected enum `std::option::Option<bool>`
found enum `std::result::Result<bool, identity_iota::credential::status_list_2021::status_list::StatusListError>`
|
mismatched types:
src/credential/revocation/status_list_2021/status_list.rs#L42
error[E0308]: mismatched types
--> src/credential/revocation/status_list_2021/status_list.rs:42:5
|
41 | pub fn set(&mut self, index: usize, value: bool) {
| - expected `()` because of default return type
42 | self.0.set(index, value)
| ^^^^^^^^^^^^^^^^^^^^^^^^ expected `()`, found `Result<(), StatusListError>`
|
= note: expected unit type `()`
found enum `std::result::Result<(), identity_iota::credential::status_list_2021::status_list::StatusListError>`
help: consider using a semicolon here
|
42 | self.0.set(index, value);
| +
help: consider using `Result::expect` to unwrap the `std::result::Result<(), identity_iota::credential::status_list_2021::status_list::StatusListError>` value, panicking if the value is a `Result::Err`
|
42 | self.0.set(index, value).expect("REASON")
| +++++++++++++++++
|
clippy
Clippy had exited with the 101 exit code
|
clippy
The following actions uses node12 which is deprecated and will be forced to run on node16: jetli/wasm-bindgen-action@24ba6f9fff570246106ac3f80f35185600c3f6c9. For more info: https://github.blog/changelog/2023-06-13-github-actions-all-actions-will-run-on-node16-instead-of-node12-by-default/
|