Skip to content

Commit

Permalink
testmempoolaccept maxfeerate f32 -> f64
Browse files Browse the repository at this point in the history
  • Loading branch information
mononaut committed Mar 25, 2024
1 parent 2ce0604 commit 78b03cb
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/daemon.rs
Original file line number Diff line number Diff line change
Expand Up @@ -605,7 +605,7 @@ impl Daemon {
pub fn test_mempool_accept(
&self,
txhex: Vec<String>,
maxfeerate: Option<f32>,
maxfeerate: Option<f64>,
) -> Result<Vec<MempoolAcceptResult>> {
let params = match maxfeerate {
Some(rate) => json!([txhex, format!("{:.8}", rate)]),
Expand Down
2 changes: 1 addition & 1 deletion src/new_index/query.rs
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ impl Query {
pub fn test_mempool_accept(
&self,
txhex: Vec<String>,
maxfeerate: Option<f32>,
maxfeerate: Option<f64>,
) -> Result<Vec<MempoolAcceptResult>> {
self.daemon.test_mempool_accept(txhex, maxfeerate)
}
Expand Down
2 changes: 1 addition & 1 deletion src/rest.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1215,7 +1215,7 @@ fn handle_request(
let maxfeerate = query_params
.get("maxfeerate")
.map(|s| {
s.parse::<f32>()
s.parse::<f64>()
.map_err(|_| HttpError::from("Invalid maxfeerate".to_string()))
})
.transpose()?;
Expand Down

0 comments on commit 78b03cb

Please sign in to comment.