Skip to content

Commit a649b58

Browse files
authored
[k2] disable diagnostics for not found confdata key and wildcard (#1581)
This reverts commit 45bd65a. The reason for revert: this diagnostics emits too much false positives
1 parent 77038e5 commit a649b58

1 file changed

Lines changed: 0 additions & 6 deletions

File tree

runtime-light/stdlib/confdata/confdata-functions.cpp

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,6 @@ kphp::coro::task<mixed> f$confdata_get_value(string key) noexcept {
7777
kphp::log::assertion(maybe_confdata_value.fetch(tlf));
7878

7979
if (!maybe_confdata_value.opt_value) { // no such key
80-
kphp::log::warning("key isn't found: {}", confdata_get.key.value);
8180
co_return mixed{};
8281
}
8382

@@ -121,11 +120,6 @@ kphp::coro::task<array<mixed>> f$confdata_get_values_by_any_wildcard(string wild
121120
tl::Dictionary<tl::confdataValue> dict_confdata_value{};
122121
kphp::log::assertion(dict_confdata_value.fetch(tlf));
123122

124-
if (dict_confdata_value.size() == 0) {
125-
kphp::log::warning("wildcard doesn't match any key: {}", confdata_get_wildcard.wildcard.value);
126-
co_return array<mixed>{};
127-
}
128-
129123
array<mixed> result{array_size{static_cast<int64_t>(dict_confdata_value.size()), false}};
130124
std::ranges::for_each(dict_confdata_value, [&result, wildcard_size = wildcard_view.size()](const auto& dict_field) noexcept {
131125
kphp::log::assertion(dict_field.key.value.size() >= wildcard_size);

0 commit comments

Comments
 (0)