pp-chat: Update ui_data only if non-NULL

Otherwise we are dereferencing a NULL value

Likely Fixes #415
8 jobs for master
in 11 minutes and 38 seconds, using 0.0 compute credits, and was queued for 4 seconds