fix to cast of uid