mirror of
https://github.com/XRPLF/rippled.git
synced 2026-04-29 15:37:57 +00:00
Fix comment and fix formatting
Signed-off-by: JCW <a1q123456@users.noreply.github.com>
This commit is contained in:
@@ -130,7 +130,7 @@ public:
|
||||
@param replaceCallback Function that decides if cache should be replaced
|
||||
|
||||
@return First item: `true` If the key already existed; Second item: The
|
||||
in the cache.
|
||||
canonicalized item.
|
||||
*/
|
||||
template <class R>
|
||||
std::pair<bool, SharedPointerType>
|
||||
|
||||
@@ -501,8 +501,7 @@ TaggedCache<
|
||||
key_type const& key,
|
||||
SharedPointerType const& data)
|
||||
{
|
||||
auto [alreadyExists, _] = canonicalize(
|
||||
key, data, []() { return true; });
|
||||
auto [alreadyExists, _] = canonicalize(key, data, []() { return true; });
|
||||
return alreadyExists;
|
||||
}
|
||||
|
||||
@@ -527,7 +526,8 @@ TaggedCache<
|
||||
Mutex>::
|
||||
canonicalize_replace_client(key_type const& key, SharedPointerType& data)
|
||||
{
|
||||
auto [alreadyExists, itemInCache] = canonicalize(key, data, []() { return false; });
|
||||
auto [alreadyExists, itemInCache] =
|
||||
canonicalize(key, data, []() { return false; });
|
||||
data = itemInCache;
|
||||
return alreadyExists;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user