mirror of
https://github.com/logos-blockchain/lssa.git
synced 2026-01-07 15:53:14 +00:00
Merge branch 'main' into Pravdyvy/structural-improvements
This commit is contained in:
commit
1cdf058938
0
ci_scripts/lint-ubuntu.sh
Normal file → Executable file
0
ci_scripts/lint-ubuntu.sh
Normal file → Executable file
@ -2,11 +2,11 @@ use nssa_core::{
|
|||||||
account::Nonce,
|
account::Nonce,
|
||||||
program::{InstructionData, ProgramId},
|
program::{InstructionData, ProgramId},
|
||||||
};
|
};
|
||||||
use serde::{Deserialize, Serialize};
|
use serde::Serialize;
|
||||||
|
|
||||||
use crate::{Address, error::NssaError, program::Program};
|
use crate::{Address, error::NssaError, program::Program};
|
||||||
|
|
||||||
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Eq)]
|
#[derive(Debug, Clone, PartialEq, Eq)]
|
||||||
pub struct Message {
|
pub struct Message {
|
||||||
pub(crate) program_id: ProgramId,
|
pub(crate) program_id: ProgramId,
|
||||||
pub(crate) addresses: Vec<Address>,
|
pub(crate) addresses: Vec<Address>,
|
||||||
|
|||||||
@ -15,7 +15,7 @@ impl PublicKey {
|
|||||||
Self(value)
|
Self(value)
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn try_new(value: [u8; 32]) -> Result<Self, NssaError> {
|
pub(super) fn try_new(value: [u8; 32]) -> Result<Self, NssaError> {
|
||||||
// Check point is valid
|
// Check point is valid
|
||||||
let _ = secp256k1::XOnlyPublicKey::from_byte_array(value)
|
let _ = secp256k1::XOnlyPublicKey::from_byte_array(value)
|
||||||
.map_err(|_| NssaError::InvalidPublicKey)?;
|
.map_err(|_| NssaError::InvalidPublicKey)?;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user