title: MEAN - router.get method is not triggering
body: <p>My requirement is pretty straightforward. I am trying to load a configurable <code>angular component</code> if configuration is not done yet. I have been trying to send a get request to server to find out a record already exists - if exists it would redirect to other <code>angular component</code> or keep in current <code>angular component</code> to configure.</p>
  
  <p>I configured my <code>express</code> application for router in the following way -</p>
  
  <pre><code>const admin_routes = require('./server/routes/admin');
  const configure_routes = require('./server/routes/configure');
  
  app.use(mongooseExpressErrorHandler);
  
  app.use(bodyParser.json());
  app.use(bodyParser.urlencoded({extended: false}));
  
  app.use(express.static(path.join(__dirname, 'dist/product-bot')));
  app.use(express.static(__dirname + '/server/images'));
  
  app.use('/admin', admin_routes);
  app.use('/configure', configure_routes);
  
  app.get('*', (req, res) =&gt; {
      res.sendFile(path.join(__dirname, 'dist/products/index.html'));
  });
  
  app.post('*', (req, res) =&gt; {
      res.sendFile(path.join(__dirname, 'dist/products/index.html'));
  });
  </code></pre>
  
  <p>Here is the router -</p>
  
  <pre><code>const express       = require('express');;
  const configureController = require('../controller/configure/configure');
  const router        = express.Router();
  
  router.get('/configure', configureController.check_super_admin_exists);
  </code></pre>
  
  <p>Here is my controller code -</p>
  
  <pre><code>exports.check_super_admin_exists = function(req, res, next) {
    let find_super_admin_promise = userModel.find_user_by_role();
  
    find_super_admin_promise.then(function(result) {
  
      if (typeof result === 'undefined' || result === null) {
        res.redirect('/login');
      } else {
        next();
      }
    }).catch(function(error) {
      console.log(error);
      res.status(500);
      res.json('error');
    });
  }
  </code></pre>
  
  <p><code>userModel.find_user_by_role()</code> is working fine as I already use the model code in another feature.</p>
  
  <p>But the problem is - I see my router code (<code>router.get('/configure', configureController.check_super_admin_exists)</code>) is never being executed. I have been working with <code>router.post()</code> method in the same project and it works fine.</p>
  
  <p>Can you please help me with finding out what is the issue with my code.</p>
  
  <p>Thanks in advance.</p>