Added support for null as first arg in createClass