fix agent type condition, RT#12539