Skip to content

Commit

Permalink
Remove redundant function in JS
Browse files Browse the repository at this point in the history
  • Loading branch information
getdave authored and jeryj committed Jan 31, 2025
1 parent d9d589a commit ce3b588
Showing 1 changed file with 0 additions and 16 deletions.
16 changes: 0 additions & 16 deletions projects/packages/jitm/src/js/jetpack-jitm.js
Original file line number Diff line number Diff line change
Expand Up @@ -336,22 +336,6 @@ jQuery( document ).ready( function ( $ ) {
} );
};

const makeAjaxRequest = function ( method, url, contentType, body = null, callback = null ) {
const xhr = new XMLHttpRequest();
xhr.open( method, url, true );
xhr.setRequestHeader( 'X-Requested-With', 'XMLHttpRequest' );
if ( contentType ) {
xhr.setRequestHeader( 'Content-Type', contentType );
}
xhr.withCredentials = true;
if ( callback ) {
xhr.onreadystatechange = function () {
callback( xhr );
};
}
xhr.send( body );
};

reFetch();

$( window ).on( 'hashchange', function ( e ) {
Expand Down

0 comments on commit ce3b588

Please sign in to comment.