From e01f1a94b4add438cc72f19c321cded4a669682e Mon Sep 17 00:00:00 2001 From: Emil Lenngren Date: Mon, 16 May 2022 01:51:23 +0200 Subject: [PATCH] Use reference instead of copy --- libultraship/libultraship/SohHooks.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libultraship/libultraship/SohHooks.h b/libultraship/libultraship/SohHooks.h index d9304c3ad..b5dec8159 100644 --- a/libultraship/libultraship/SohHooks.h +++ b/libultraship/libultraship/SohHooks.h @@ -22,7 +22,7 @@ namespace ModInternal { template void ExecuteHooks(Args&&... args) { - for (auto fn : RegisteredHooks::functions) { + for (auto& fn : RegisteredHooks::functions) { fn(std::forward(args)...); } }