mirror of
https://github.com/ceph/ceph
synced 2024-12-18 01:16:55 +00:00
osd: use static method and simplify return
Signed-off-by: Noah Watkins <noahwatkins@gmail.com>
This commit is contained in:
parent
4025a2eb80
commit
298bc93954
@ -102,10 +102,7 @@ bool ClassHandler::in_class_list(const std::string& cname,
|
||||
auto it = std::find_first_of(begin, end,
|
||||
targets.begin(), targets.end());
|
||||
|
||||
if (it == end)
|
||||
return false;
|
||||
|
||||
return true;
|
||||
return it != end;
|
||||
}
|
||||
|
||||
ClassHandler::ClassData *ClassHandler::_get_class(const string& cname,
|
||||
|
@ -106,7 +106,7 @@ private:
|
||||
ClassData *_get_class(const string& cname, bool check_allowed);
|
||||
int _load_class(ClassData *cls);
|
||||
|
||||
bool in_class_list(const std::string& cname,
|
||||
static bool in_class_list(const std::string& cname,
|
||||
const std::string& list);
|
||||
|
||||
public:
|
||||
|
Loading…
Reference in New Issue
Block a user