How can I check whether a variable is defined in Node Js code example Example: How can I check whether a variable is defined in Node Js if (query){ doStuff(); }