Prevent Javascript constructor from creating new instance if certain argument isn't provided?

后端 未结 0 1902
情深已故
情深已故 2020-12-30 23:19

I want to prevent the constructor from instantiating new object, if an argument is not provided.Also in that case i like to return null. But the constructor is creating an o

相关标签:
回答
  • 消灭零回复
提交回复
热议问题