Skip to content

Commit 1e06320

Browse files
committedJul 24, 2017
Prepare for list by company/tags.
Signed-off-by: Eric Wang <skygragon@gmail.com>
1 parent 2e9141b commit 1e06320

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed
 

‎lib/commands/list.js

+5-1
Original file line numberDiff line numberDiff line change
@@ -86,8 +86,12 @@ cmd.handler = function(argv) {
8686
}
8787

8888
if (argv.tag) {
89+
var tag = argv.tag;
90+
// TODO: fill company/tags in problems
8991
problems = _.filter(problems, function(x) {
90-
return x.category === argv.tag;
92+
return x.category === tag ||
93+
x.company === tag ||
94+
(x.tags && x.tags.indexOf(tag) !== -1);
9195
});
9296
}
9397

‎test/test_plugin.js

-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
var _ = require('underscore');
21
var assert = require('chai').assert;
32
var rewire = require('rewire');
43

0 commit comments

Comments
 (0)
Please sign in to comment.