mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2026-07-25 06:54:43 +00:00
Fix crash in new phone formatting.
This commit is contained in:
@@ -355,6 +355,9 @@ FormatResult CountriesInstance::format(FormatArgs args) {
|
||||
? QVector<int>()
|
||||
: QVector<int>{ codeSize };
|
||||
auto groupSize = 0;
|
||||
if (bestCallingCodePtr->patterns.empty()) {
|
||||
return FormatResult{ .groups = std::move(groups) };
|
||||
}
|
||||
for (const auto &c : bestCallingCodePtr->patterns.front()) {
|
||||
if (c == ' ') {
|
||||
groups.push_back(base::take(groupSize));
|
||||
|
||||
Reference in New Issue
Block a user