Blame view

lib/http-command-server/router-info.js 244 Bytes
3ec3e9eb3   Adhidarma Hadiwinoto   HTTP command serv...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
  'use strict';
  
  const express = require('express');
  
  const modem = require('../modem');
  
  const router = express.Router();
  module.exports = router;
  
  function handlerMain(req, res) {
      res.json(modem.modemInfo);
  }
  
  router.get('/', handlerMain);