fixed and removed unused ajax calls