modif condition isAjaxRequest