Unhandled exception in GlideAjax

Lisa Silvaroli
Tera Guru

I have a catalog client script that keeps giving "There is a JavaScript error in your browser console" 

The console just says "Unhandled exception in GlideAjax."

This is the code I believe it is having the issue with:

var ga = new GlideAjax('StaffInfoAjax3');
			ga.addParam('sysparm_name', 'getStaffInfo');
			ga.addParam('sysparm_staff', staffId);
			ga.addParam('sysparm_access_action', pass_action);
			ga.getXMLAnswer(response);
			ga.getXMLAnswer(function(response){
			response = JSON.parse(response);

What do I need to change to make it work?