Remove unnecessary & from AsRef params (#22523)
This commit is contained in:
@ -158,7 +158,7 @@ impl<T: Serialize + Clone> StatusCache<T> {
|
|||||||
/// to search all blockhashes.
|
/// to search all blockhashes.
|
||||||
pub fn get_status_any_blockhash<K: AsRef<[u8]>>(
|
pub fn get_status_any_blockhash<K: AsRef<[u8]>>(
|
||||||
&self,
|
&self,
|
||||||
key: &K,
|
key: K,
|
||||||
ancestors: &Ancestors,
|
ancestors: &Ancestors,
|
||||||
) -> Option<(Slot, T)> {
|
) -> Option<(Slot, T)> {
|
||||||
let mut keys = vec![];
|
let mut keys = vec![];
|
||||||
@ -167,7 +167,7 @@ impl<T: Serialize + Clone> StatusCache<T> {
|
|||||||
|
|
||||||
for blockhash in keys.iter() {
|
for blockhash in keys.iter() {
|
||||||
trace!("get_status_any_blockhash: trying {}", blockhash);
|
trace!("get_status_any_blockhash: trying {}", blockhash);
|
||||||
let status = self.get_status(key, blockhash, ancestors);
|
let status = self.get_status(&key, blockhash, ancestors);
|
||||||
if status.is_some() {
|
if status.is_some() {
|
||||||
return status;
|
return status;
|
||||||
}
|
}
|
||||||
@ -190,7 +190,7 @@ impl<T: Serialize + Clone> StatusCache<T> {
|
|||||||
pub fn insert<K: AsRef<[u8]>>(
|
pub fn insert<K: AsRef<[u8]>>(
|
||||||
&mut self,
|
&mut self,
|
||||||
transaction_blockhash: &Hash,
|
transaction_blockhash: &Hash,
|
||||||
key: &K,
|
key: K,
|
||||||
slot: Slot,
|
slot: Slot,
|
||||||
res: T,
|
res: T,
|
||||||
) {
|
) {
|
||||||
|
Reference in New Issue
Block a user