Modify regex to recognize edition from jason #4933
This commit is contained in:
parent
ad16599fa5
commit
2fd0d5c68f
|
@ -50,7 +50,7 @@ int WebClient::getEdition(
|
|||
if (resultRegex.exactMatch(responseJson)) {
|
||||
QString boolString = resultRegex.cap(1);
|
||||
if (boolString == "true") {
|
||||
QRegExp editionRegex(".*\"edition\".*:.*\"([^\"]+)\".*");
|
||||
QRegExp editionRegex(".*\"edition\":(0|1|2|3).*");
|
||||
if (editionRegex.exactMatch(responseJson)) {
|
||||
QString e = editionRegex.cap(1);
|
||||
edition = e.toInt();
|
||||
|
|
Loading…
Reference in New Issue