Skip to content

Commit

Permalink
patch integration tests
Browse files Browse the repository at this point in the history
  • Loading branch information
TrySound authored and ben-eb committed Feb 26, 2017
1 parent 3ce5166 commit 951f47d
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions packages/postcss-discard-duplicates/index.js
Expand Up @@ -3,13 +3,14 @@
var postcss = require('postcss');

function dedupe (root) {
root.nodes.forEach(function (node) {
root.each(function (node) {
if (node.nodes) { dedupe(node); }
});

root.nodes.forEach(function (node, index, nodes) {
root.each(function (node, index) {
if (node.type === 'comment') { return; }

var nodes = node.parent.nodes;
var toString = node.toString();
var result = [node];
var i = index + 1;
Expand Down

0 comments on commit 951f47d

Please sign in to comment.