Fix warnings from clippy

This commit is contained in:
aniampio
2021-10-22 17:59:53 +02:00
parent 5bf0a14c20
commit 8250dca8be
3 changed files with 2 additions and 9 deletions
+2 -2
View File
@@ -9,7 +9,7 @@
use url::Url;
use coconut_interface::{
Attribute, Credential, Parameters, PrivateAttribute, PublicAttribute,
Credential, Parameters, PrivateAttribute, PublicAttribute,
Signature, VerificationKey,
};
@@ -75,7 +75,7 @@ pub fn prepare_for_spending(
attributes: &BandwidthVoucherAttributes,
verification_key: &VerificationKey,
) -> Result<Credential, Error> {
let public_attributes = vec![BANDWIDTH_VALUE.to_be_bytes().to_vec()];
let public_attributes = vec![raw_identity.to_vec(), BANDWIDTH_VALUE.to_be_bytes().to_vec()];
let params = Parameters::new(TOTAL_ATTRIBUTES)?;
-2
View File
@@ -1,8 +1,6 @@
// Copyright 2021 - Nym Technologies SA <contact@nymtech.net>
// SPDX-License-Identifier: Apache-2.0
use std::borrow::Borrow;
use url::Url;
use coconut_interface::{
-5
View File
@@ -56,11 +56,6 @@ pub type Attribute = Scalar;
pub type PrivateAttribute = Attribute;
pub type PublicAttribute = Attribute;
pub struct BandwidthPrivateAttributes {
serial_number: Attribute,
binding_number: Attribute,
}
impl Bytable for Attribute {
fn to_byte_vec(&self) -> Vec<u8> {
self.to_bytes().to_vec()