Fixed bizarre bug in rest_ui