From e4ba06c828d4bf9a9dc15ea67fac6826dfcf5964 Mon Sep 17 00:00:00 2001 From: ariel- Date: Mon, 5 Jun 2017 03:29:02 -0300 Subject: [PATCH] Core/Utils: restored previous behaviour of RandomResize --- src/common/Utilities/Containers.h | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/common/Utilities/Containers.h b/src/common/Utilities/Containers.h index 10d6d18a74c..8745cd4abeb 100644 --- a/src/common/Utilities/Containers.h +++ b/src/common/Utilities/Containers.h @@ -114,12 +114,10 @@ namespace Trinity { //! First use predicate filter C containerCopy; + std::copy_if(std::begin(container), std::end(container), std::inserter(containerCopy, std::end(containerCopy)), predicate); if (requestedSize) - { - std::copy_if(std::begin(container), std::end(container), std::inserter(containerCopy, std::end(containerCopy)), predicate); RandomResize(containerCopy, requestedSize); - } container = std::move(containerCopy); }