Skip to content

Commit

Permalink
Merge 97ea1d6 into 21573d6
Browse files Browse the repository at this point in the history
  • Loading branch information
yavuzmester committed Nov 4, 2016
2 parents 21573d6 + 97ea1d6 commit bdd09dd
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 20 deletions.
5 changes: 5 additions & 0 deletions .gitignore
Expand Up @@ -27,6 +27,11 @@ coverage/
node_modules/
npm-debug.log

#
# Ide folders.
#
.idea/

#
# OS X.
#
Expand Down
22 changes: 7 additions & 15 deletions index.js
@@ -1,17 +1,9 @@
/**
* Module dependencies.
*/
module.exports = function (degrees) {
"use strict";

var assert = require('assert');
if (typeof degrees !== 'number') {
throw new TypeError('Degrees should be a number');
}

/**
* Convert degrees to radians.
*
* @param {Number} degrees
* @return {Number}
*/

module.exports = function(degrees) {
assert('number' == typeof degrees, 'Degrees should be a number');
return degrees * (Math.PI / 180);
}
return degrees * (Math.PI / 180);
};
10 changes: 5 additions & 5 deletions package.json
@@ -1,18 +1,18 @@
{
"name": "degrees-radians",
"version": "1.0.3",
"name": "@yavuzmester/degrees-radians",
"version": "1.0.4",
"description": "Convert degrees to radians",
"main": "index.js",
"scripts": {
"test": "NODE_ENV=test ./node_modules/mocha/bin/mocha --recursive --harmony-generators -R spec",
"test": "mocha",
"coverage": "node ./node_modules/istanbul/lib/cli.js cover ./node_modules/mocha/bin/_mocha --report text --recursive -- -R spec && rm -rf ./coverage/"
},
"repository": {
"type": "git",
"url": "https://github.com/yoshuawuyts/degrees-radians"
"url": "https://github.com/yavuzmester/degrees-radians"
},
"keywords": [],
"author": "Yoshua Wuyts <i@yoshuawuyts.com>",
"author": "Yavuz Mester",
"license": "MIT",
"devDependencies": {
"coveralls": "^2.10.0",
Expand Down

0 comments on commit bdd09dd

Please sign in to comment.