mirror of
https://github.com/commons-app/apps-android-commons.git
synced 2025-10-26 20:33:53 +01:00
The value is the user language. If null or empty the value "user" is used
This commit is contained in:
parent
b673527467
commit
a4238c03df
1 changed files with 6 additions and 0 deletions
|
|
@ -566,6 +566,11 @@ public class ApacheHttpClientMediaWikiApi implements MediaWikiApi {
|
|||
}else {
|
||||
notfilter = "!read";
|
||||
}
|
||||
String language=Locale.getDefault().getLanguage();
|
||||
if(StringUtils.isNullOrWhiteSpace(language)){
|
||||
//if no language is set we use the default user language defined on wikipedia
|
||||
language="user";
|
||||
}
|
||||
notificationNode = api.action("query")
|
||||
.param("notprop", "list")
|
||||
.param("format", "xml")
|
||||
|
|
@ -573,6 +578,7 @@ public class ApacheHttpClientMediaWikiApi implements MediaWikiApi {
|
|||
.param("notformat", "model")
|
||||
.param("notwikis", "wikidatawiki|commonswiki|enwiki")
|
||||
.param("notfilter", notfilter)
|
||||
.param("uselang", language)
|
||||
.get()
|
||||
.getNode("/api/query/notifications/list");
|
||||
} catch (IOException e) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue