Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 10 additions & 10 deletions contract-tests/bittensor/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ pub trait RuntimeReadWrite {
fn remove_stake_full_limit(
hotkey: <CustomEnvironment as ink::env::Environment>::AccountId,
netuid: u16,
limit_price: u64,
limit_price: Option<u64>,
);

#[ink(function = 12)]
Expand All @@ -152,15 +152,15 @@ pub trait RuntimeReadWrite {
#[ink(function = 16)]
fn recycle_alpha(
hotkey: <CustomEnvironment as ink::env::Environment>::AccountId,
amount: u64,
netuid: u16,
amount: u64,
) -> u64;

#[ink(function = 17)]
fn burn_alpha(
hotkey: <CustomEnvironment as ink::env::Environment>::AccountId,
amount: u64,
netuid: u16,
amount: u64,
) -> u64;

#[ink(function = 18)]
Expand Down Expand Up @@ -255,7 +255,7 @@ pub trait RuntimeReadWrite {
fn caller_remove_stake_full_limit(
hotkey: <CustomEnvironment as ink::env::Environment>::AccountId,
netuid: u16,
limit_price: u64,
limit_price: Option<u64>,
);

#[ink(function = 31)]
Expand Down Expand Up @@ -508,7 +508,7 @@ mod bittensor {
&self,
hotkey: [u8; 32],
netuid: u16,
limit_price: u64,
limit_price: Option<u64>,
) -> Result<(), ReadWriteErrorCode> {
self.env()
.extension()
Expand Down Expand Up @@ -556,25 +556,25 @@ mod bittensor {
pub fn recycle_alpha(
&self,
hotkey: [u8; 32],
amount: u64,
netuid: u16,
amount: u64,
) -> Result<u64, ReadWriteErrorCode> {
self.env()
.extension()
.recycle_alpha(hotkey.into(), amount, netuid)
.recycle_alpha(hotkey.into(), netuid, amount)
.map_err(|_e| ReadWriteErrorCode::WriteFailed)
}

#[ink(message)]
pub fn burn_alpha(
&self,
hotkey: [u8; 32],
amount: u64,
netuid: u16,
amount: u64,
) -> Result<u64, ReadWriteErrorCode> {
self.env()
.extension()
.burn_alpha(hotkey.into(), amount, netuid)
.burn_alpha(hotkey.into(), netuid, amount)
.map_err(|_e| ReadWriteErrorCode::WriteFailed)
}

Expand Down Expand Up @@ -766,7 +766,7 @@ mod bittensor {
&self,
hotkey: [u8; 32],
netuid: u16,
limit_price: u64,
limit_price: Option<u64>,
) -> Result<(), ReadWriteErrorCode> {
self.env()
.extension()
Expand Down
Loading
Loading