Skip to content

Commit 0258f61

Browse files
committed
Review: var for older node versions
1 parent 25d7378 commit 0258f61

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

bin/json-graphql-server.js

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,19 @@
11
#!/usr/bin/env node
22
require('reify');
3-
const path = require('path');
4-
const express = require('express');
5-
const cors = require('cors');
6-
const JsonGraphqlServer = require('../lib/json-graphql-server.node.min').default;
3+
var path = require('path');
4+
var express = require('express');
5+
var cors = require('cors');
6+
var JsonGraphqlServer = require('../lib/json-graphql-server.node.min').default;
77

8-
const dataFilePath = process.argv.length > 2 ? process.argv[2] : './data.json';
9-
const data = require(path.join(process.cwd(), dataFilePath));
10-
const PORT = 3000;
11-
const app = express();
8+
var dataFilePath = process.argv.length > 2 ? process.argv[2] : './data.json';
9+
var data = require(path.join(process.cwd(), dataFilePath));
10+
var PORT = 3000;
11+
var app = express();
1212

1313
app.use(cors());
1414
app.use('/', JsonGraphqlServer(data));
1515
app.listen(PORT);
16-
const msg = `GraphQL server running with your data at http://localhost:${PORT}/`;
16+
var msg = `GraphQL server running with your data at http://localhost:${PORT}/`;
1717
console.log(msg); // eslint-disable-line no-console
1818

1919
process.on('unhandledRejection', (reason, p) => {

0 commit comments

Comments
 (0)