Add option to limit number of TXs shown (#660)

Co-authored-by: cliik <cliik@example.com>
This commit is contained in:
cliik
2022-07-26 10:16:47 +01:00
committed by GitHub
co-authored by cliik
parent ef3fadbd24
commit a3687c69a8
3 changed files with 16 additions and 1 deletions
+5
View File
@@ -840,9 +840,14 @@ pub fn parse_txs_args(args: &ArgMatches) -> Result<command::TxsArgs, ParseError>
let msg = format!("At most one of 'id' (-i) or 'txid' (-t) may be provided.");
return Err(ParseError::ArgumentError(msg));
}
let count = match args.value_of("count") {
None => None,
Some(c) => Some(parse_u64(c, "count")? as u32),
};
Ok(command::TxsArgs {
id: tx_id,
tx_slate_id: tx_slate_id,
count: count,
})
}