fix bug when no userData is not present