Skip to content

Commit

Permalink
Merge pull request #95 from SemanticMediaWiki/PeterTheOne-patch-1
Browse files Browse the repository at this point in the history
replace static api url
  • Loading branch information
JeroenDeDauw authored Aug 16, 2016
2 parents f6bc5c3 + 71ac766 commit a492939
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/ext.sm.common.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
* @licence GNU GPL v2++
* @author Peter Grassberger < [email protected] >
*/
window.sm = new ( function( $ ) {
window.sm = new ( function( $, mw ) {

this.buildQueryString = function( query, ajaxcoordproperty, top, right, bottom, left ) {
query += ' [[' + ajaxcoordproperty + '::+]] ';
Expand All @@ -18,7 +18,7 @@ window.sm = new ( function( $ ) {
this.sendQuery = function( query ) {
return $.ajax( {
method: 'GET',
url: '/w/api.php?',
url: mw.util.wikiScript( 'api' ),
data: {
'action': 'ask',
'query': query,
Expand Down Expand Up @@ -53,4 +53,4 @@ window.sm = new ( function( $ ) {
} );
};

} )( jQuery );
} )( jQuery, mediaWiki );

0 comments on commit a492939

Please sign in to comment.