title: Jade - Template Engine: How to check if a variable exists
body: <p>I'm currently using Jade on a new project. I want to render a page and check if a certain variable is available.</p>
  
  <p><code>app.js</code>:</p>
  
  <pre><code>app.get('/register', function(req, res){
      res.render('register', {
          locals: {
            title: 'Register',
            text: 'Register as a user.',
          }
        });
  });
  </code></pre>
  
  <p><code>register.jade</code>:</p>
  
  <pre><code>- if (username)
  p= username
  - else
  p No Username!
  </code></pre>
  
  <p>I always get the following error:</p>
  
  <pre><code>username is not defined
  </code></pre>
  
  <p>Any ideas on how I can fix this?</p>