Skip to content

Commit e96db8e

Browse files
committed
RE #2: Add support for Node.js 4.x, update copyright and dependencies.
1 parent 5164bfc commit e96db8e

File tree

7 files changed

+24
-14
lines changed

7 files changed

+24
-14
lines changed

CHANGELOG.md

+5
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
# Changelog
22

3+
## 0.1.4 (January 18, 2016)
4+
* Bugfix: add support for Node.js 4.x.
5+
* Updated copyright to `2016`.
6+
* Updated dependencies.
7+
38
## 0.1.3 (July 31, 2015)
49
* Bugfix: uncss now ignores external stylesheets.
510

LICENSE.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
The MIT License (MIT)
22

3-
Copyright (c) 2015 Mark van Seventer
3+
Copyright (c) 2016 Mark van Seventer
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ See the [Changelog](./CHANGELOG.md) for a list of changes.
3232
## License
3333
The MIT License (MIT)
3434

35-
Copyright (c) 2015 Mark van Seventer
35+
Copyright (c) 2016 Mark van Seventer
3636

3737
Permission is hereby granted, free of charge, to any person obtaining a copy
3838
of this software and associated documentation files (the "Software"), to deal

index.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/**
22
* The MIT License (MIT)
33
*
4-
* Copyright (c) 2015 Mark van Seventer
4+
* Copyright (c) 2016 Mark van Seventer
55
*
66
* Permission is hereby granted, free of charge, to any person obtaining a copy
77
* of this software and associated documentation files (the "Software"), to deal

lib/filter.js

+7-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/**
22
* The MIT License (MIT)
33
*
4-
* Copyright (c) 2015 Mark van Seventer
4+
* Copyright (c) 2016 Mark van Seventer
55
*
66
* Permission is hereby granted, free of charge, to any person obtaining a copy
77
* of this software and associated documentation files (the "Software"), to deal
@@ -63,7 +63,12 @@ module.exports = function(str, locals) {
6363
// Retrieve raw HTML from HTML files.
6464
var promise = Promise.map(routes, function(path) {
6565
var stream = route.get(path);
66-
return streamToArrayAsync(stream).then(Buffer.concat);
66+
return streamToArrayAsync(stream).then(function(arr) {
67+
var buffers = arr.map(function(el) {
68+
return el instanceof Buffer ? el : new Buffer(el);
69+
});
70+
return Buffer.concat(buffers).toString();
71+
});
6772
});
6873

6974
// UnCSS the raw HTML with the CSS provided.

package.json

+8-8
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name" : "hexo-uncss",
3-
"version" : "0.1.3",
3+
"version" : "0.1.4",
44
"description" : "uncss plugin for Hexo.",
55
"keywords" : [ "hexo", "hexo-plugin", "hexo-filter", "uncss", "css", "html" ],
66
"homepage" : "https://github.com/vseventer/hexo-uncss",
@@ -14,17 +14,17 @@
1414
"test" : "./node_modules/.bin/mocha test/"
1515
},
1616
"dependencies": {
17-
"bluebird" : "2.9.x",
17+
"bluebird" : "3.1.x",
1818
"debug" : "2.2.x",
19-
"minimatch" : "2.0.x",
20-
"object-assign" : "3.0.x",
21-
"stream-to-array" : "2.0.x",
19+
"minimatch" : "3.0.x",
20+
"object-assign" : "4.0.x",
21+
"stream-to-array" : "2.2.x",
2222
"uncss" : "0.12.x"
2323
},
2424
"devDependencies": {
25-
"jshint" : "2.8.x",
26-
"jshint-stylish" : "2.0.x",
27-
"mocha" : "2.2.x"
25+
"jshint" : "2.9.x",
26+
"jshint-stylish" : "2.1.x",
27+
"mocha" : "2.3.x"
2828
},
2929
"engines": { "node" : ">=0.10.x" }
3030
}

test/filter.test.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/**
22
* The MIT License (MIT)
33
*
4-
* Copyright (c) 2015 Mark van Seventer
4+
* Copyright (c) 2016 Mark van Seventer
55
*
66
* Permission is hereby granted, free of charge, to any person obtaining a copy
77
* of this software and associated documentation files (the "Software"), to deal

0 commit comments

Comments
 (0)