Deprecate Scope::Lookup(), replace with Scope::Find()

This commit is contained in:
Jon Siwek 2020-05-12 22:20:42 -07:00
parent a5762c12cc
commit 8f95a2a0bb
27 changed files with 65 additions and 72 deletions

View file

@ -1182,7 +1182,7 @@ WriterFrontend* Manager::CreateWriter(EnumVal* id, EnumVal* writer, WriterBacken
if ( ! found_filter_match )
{
ID* id = global_scope()->Lookup("Log::default_rotation_interval");
const auto& id = global_scope()->Find("Log::default_rotation_interval");
assert(id);
winfo->interval = id->GetVal()->AsInterval();
}
@ -1525,7 +1525,7 @@ bool Manager::FinishedRotation(WriterFrontend* writer, const char* new_name, con
Func* func = winfo->postprocessor;
if ( ! func )
{
ID* id = global_scope()->Lookup("Log::__default_rotation_postprocessor");
const auto& id = global_scope()->Find("Log::__default_rotation_postprocessor");
assert(id);
func = id->GetVal()->AsFunc();
}