Added null check.
Added null check.

Signed-off-by: Konstantina Chremmou <a7d1f757a659045fb6db8c1e3849a1c8ad00b97a@citrix.com>

jijiang/xenadmin,geosharath/xenadmin,geosharath/xenadmin,stephen-turner/xenadmin,xenserver/xenadmin,agimofcarmen/xenadmin,stephen-turner/xenadmin,qlw/xenadmin,stephen-turner/xenadmin,cheng--zhang/xenadmin,qlw/xenadmin,GaborApatiNagy/xenadmin,cheng-z/xenadmin,cheng--zhang/xenadmin,geosharath/xenadmin,kc284/xenadmin,Frezzle/xenadmin,Frezzle/xenadmin,MihaelaStoica/xenadmin,minli1/xenadmin,robhoes/xenadmin,cheng--zhang/xenadmin,Frezzle/xenadmin,agimofcarmen/xenadmin,jijiang/xenadmin,jijiang/xenadmin,huizh/xenadmin,cheng-z/xenadmin,ushamandya/xenadmin,ushamandya/xenadmin,huizh/xenadmin,robhoes/xenadmin,agimofcarmen/xenadmin,cheng--zhang/xenadmin,geosharath/xenadmin,agimofcarmen/xenadmin,minli1/xenadmin,robhoes/xenadmin,kc284/xenadmin,letsboogey/xenadmin,cheng-z/xenadmin,stephen-turner/xenadmin,GaborApatiNagy/xenadmin,ushamandya/xenadmin,minli1/xenadmin,cheng-z/xenadmin,letsboogey/xenadmin,huizh/xenadmin,letsboogey/xenadmin,cheng-z/xenadmin,cheng--zhang/xenadmin,stephen-turner/xenadmin,kc284/xenadmin,robhoes/xenadmin,qlw/xenadmin,minli1/xenadmin,huizh/xenadmin,MihaelaStoica/xenadmin,MihaelaStoica/xenadmin,jijiang/xenadmin,minli1/xenadmin,jijiang/xenadmin,qlw/xenadmin,letsboogey/xenadmin,kc284/xenadmin,robhoes/xenadmin,MihaelaStoica/xenadmin,GaborApatiNagy/xenadmin,kc284/xenadmin,letsboogey/xenadmin,GaborApatiNagy/xenadmin,cheng-z/xenadmin,agimofcarmen/xenadmin,geosharath/xenadmin,ushamandya/xenadmin,stephen-turner/xenadmin,huizh/xenadmin,ushamandya/xenadmin,huizh/xenadmin,GaborApatiNagy/xenadmin,xenserver/xenadmin,minli1/xenadmin,GaborApatiNagy/xenadmin,robhoes/xenadmin,MihaelaStoica/xenadmin,qlw/xenadmin,Frezzle/xenadmin,letsboogey/xenadmin,cheng--zhang/xenadmin,xenserver/xenadmin,jijiang/xenadmin,geosharath/xenadmin,Frezzle/xenadmin,ushamandya/xenadmin,Frezzle/xenadmin,MihaelaStoica/xenadmin