Remove hard comparation and use is_null() function

Is there any reason why you can not make this comparison with is_null()?
I think this may be more semantic way.