CLOUDIFY-1660 added null  check