Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
ES2015-ify (#6)
  • Loading branch information
dciccale authored and sindresorhus committed Jan 19, 2017
1 parent 4f2fbbc commit 7388d5f
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 5 deletions.
1 change: 1 addition & 0 deletions .gitattributes
@@ -1 +1,2 @@
* text=auto
*.js text eol=lf
2 changes: 0 additions & 2 deletions .travis.yml
Expand Up @@ -3,5 +3,3 @@ language: node_js
node_js:
- '6'
- '4'
- '0.12'
- '0.10'
4 changes: 2 additions & 2 deletions index.js
@@ -1,7 +1,7 @@
'use strict';
module.exports = function (url) {
module.exports = url => {
if (typeof url !== 'string') {
throw new TypeError('Expected a string, got ' + typeof url);
throw new TypeError(`Expected \`url\` to be of type \`string\`, got \`${typeof url}\``);
}

url = url.trim();
Expand Down
2 changes: 1 addition & 1 deletion package.json
Expand Up @@ -10,7 +10,7 @@
"url": "sindresorhus.com"
},
"engines": {
"node": ">=0.10.0"
"node": ">=4"
},
"scripts": {
"test": "xo && ava"
Expand Down

0 comments on commit 7388d5f

Please sign in to comment.