I am looking for a smart way to check the object parameter passed to a function
<p>I am in the following situation:</p>

<p>I have to check if the object parameter passed to a function is valid:</p>

<p>Exmaple:</p>

<pre><code>function (opt) {
     if (opt &amp;&amp; opt.key &amp;&amp; opt.key2) {
         // make something
     }
}
</code></pre>

<p>Is there a better way to make this kind of check?</p>
