We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent bc1999e commit cf8edd1Copy full SHA for cf8edd1
www/core/lib/sitesmanager.js
@@ -128,8 +128,12 @@ angular.module('mm.core')
128
* @return {Promise} A promise to be resolved if the site exists.
129
*/
130
self.siteExists = function(siteurl) {
131
- // We pass fake parameters to make CORS work (without params, the script stops before allowing CORS).
132
- return $http.get(siteurl + '/login/token.php?username=a&password=b&service=c', {timeout: 30000});
+ var url = siteurl + '/login/token.php';
+ if (!ionic.Platform.isWebView()) {
133
+ // We pass fake parameters to make CORS work (without params, the script stops before allowing CORS).
134
+ url = url + '?username=a&password=b&service=c';
135
+ }
136
+ return $http.get(url, {timeout: 30000});
137
};
138
139
/**
0 commit comments