MCPcopy Create free account
hub / github.com/TDesktop-x64/tdesktop / MatchesErrorPattern

Function MatchesErrorPattern

Telegram/SourceFiles/api/api_polls.cpp:64–74  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

62
63template <size_t Size>
64[[nodiscard]] bool MatchesErrorPattern(
65 const QString &type,
66 const std::array<QString, Size> &patterns) {
67 for (const auto &pattern : patterns) {
68 if (!pattern.isEmpty()
69 && type.contains(pattern, Qt::CaseInsensitive)) {
70 return true;
71 }
72 }
73 return false;
74}
75
76[[nodiscard]] PollData::VoteRestriction ParseVoteRestrictionError(
77 const QString &type) {

Callers 1

Calls 2

isEmptyMethod · 0.45
containsMethod · 0.45

Tested by

no test coverage detected