From 62fe316637b77cced8563400e0494f0712ee2bfe Mon Sep 17 00:00:00 2001 From: Martchus Date: Mon, 7 Mar 2022 23:30:41 +0100 Subject: [PATCH] Pass `func` as `const &` in `modify` function --- lmdb-typed.hh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lmdb-typed.hh b/lmdb-typed.hh index 3f596be..ec1bd75 100644 --- a/lmdb-typed.hh +++ b/lmdb-typed.hh @@ -807,7 +807,7 @@ public: } //! Modifies an item "in place" updating indexes. - void modify(IDType id, std::function func) + void modify(IDType id, const std::function &func) { T t; if (!this->get(id, t))