-
Notifications
You must be signed in to change notification settings - Fork 24
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
19 changed files
with
4,845 additions
and
709 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
package-lock.json | ||
coverage | ||
node_modules | ||
.travis.yml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,10 @@ | ||
language: node_js | ||
node_js: | ||
- "4" | ||
- "5" | ||
- "6" | ||
- "7" | ||
- "node" | ||
- "iojs" | ||
- "8" | ||
- "9" | ||
after_success: | ||
- npm run coverage && npm run coveralls | ||
- npm run coverage && npm run coveralls |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
const | ||
TelegramServer = require('../index'), | ||
config = require('../config/config.json'), | ||
server = new TelegramServer(config); | ||
|
||
server.start(); | ||
const | ||
TelegramServer = require('../index'), | ||
config = require('../config/config.json'), | ||
server = new TelegramServer(config); | ||
|
||
server.start(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,13 @@ | ||
/** | ||
* If running on Nodejs 5.x and below, we load the transpiled code. | ||
* Otherwise, we use the ES6 code. | ||
*/ | ||
|
||
/* eslint-disable global-require*/ | ||
|
||
const majorVersion = parseInt(process.versions.node.split('.')[0], 10); | ||
if (majorVersion <= 5) { | ||
module.exports = require('./lib/telegramServer'); | ||
} else { | ||
module.exports = require('./src/telegramServer'); | ||
} | ||
/** | ||
* If running on Nodejs below 6.4, we load the transpiled code. | ||
* Otherwise, we use the ES6 code. | ||
*/ | ||
|
||
/* eslint-disable global-require */ | ||
const semver = require('semver'); | ||
|
||
if (semver.satisfies(process.version, '>=6.4.0')) { | ||
module.exports = require('./src/telegramServer'); | ||
} else { | ||
module.exports = require('./lib/telegramServer'); | ||
} |
Oops, something went wrong.