1
2
3
4
5
6
7
8
9
10
11
use common::command::{ProcessResult};
use common::math::{get_sqrt_price_at_tick, get_tick_at_sqrt_price};


pub fn process_tick_to_sqrt_price(tick: i32) -> ProcessResult {
    Ok(get_sqrt_price_at_tick(tick).to_string())
}

pub fn process_sqrt_price_to_tick(price: u128) -> ProcessResult {
    Ok(get_tick_at_sqrt_price(price).to_string())
}