kollapsminoriteten/wp-content/plugins/jetpack/modules/likes/post-count-jetpack.js

21 lines
475 B
JavaScript
Raw Normal View History

2019-11-15 23:26:29 +01:00
var wpPostLikeCount = wpPostLikeCount || {};
2020-09-15 14:30:05 +02:00
( function ( $ ) {
2019-11-15 23:26:29 +01:00
wpPostLikeCount = jQuery.extend( wpPostLikeCount, {
2020-09-15 14:30:05 +02:00
request: function ( options ) {
2019-11-15 23:26:29 +01:00
return $.ajax( {
type: 'GET',
url: wpPostLikeCount.jsonAPIbase + options.path,
dataType: 'jsonp',
data: options.data,
2020-09-15 14:30:05 +02:00
success: function ( response ) {
2019-11-15 23:26:29 +01:00
options.success( response );
},
2020-09-15 14:30:05 +02:00
error: function ( response ) {
2019-11-15 23:26:29 +01:00
options.error( response );
},
} );
},
} );
} )( jQuery );