From f2a4e4f6fa46d04f117b1b3ed498534aa30fde84 Mon Sep 17 00:00:00 2001 From: Alex Turbov Date: Mon, 27 Jun 2022 06:39:43 +0400 Subject: cmFindPackageCommand: Simplify if-return-else-return into single return stmt --- Source/cmFindPackageCommand.cxx | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/Source/cmFindPackageCommand.cxx b/Source/cmFindPackageCommand.cxx index cefd380..a763f18 100644 --- a/Source/cmFindPackageCommand.cxx +++ b/Source/cmFindPackageCommand.cxx @@ -2176,13 +2176,7 @@ public: } return *this; } - bool Search() - { - if (this->First) { - return this->First->Search(*this); - } - return false; - } + bool Search() { return this->First && this->First->Search(*this); } private: virtual bool Visit(std::string const& fullPath) = 0; -- cgit v0.12