mirror of
https://github.com/pcottle/learnGitBranching.git
synced 2025-07-17 17:23:41 +02:00
Use 'Object.values' and 'Object.keys' instead of '_.each(object)'
This commit is contained in:
parent
bd8009386d
commit
96ddb5041a
9 changed files with 52 additions and 33 deletions
|
@ -139,8 +139,11 @@ var getAllCommands = function() {
|
|||
require('../level').regexMap,
|
||||
regexMap
|
||||
);
|
||||
_.each(Commands.commands.getRegexMap(), function(map, vcs) {
|
||||
_.each(map, function(regex, method) {
|
||||
var mRegexMap = Commands.commands.getRegexMap();
|
||||
Object.keys(mRegexMap).forEach(function(vcs) {
|
||||
var map = mRegexMap[vcs];
|
||||
Object.keys(map).forEach(function(method) {
|
||||
var regex = map[method];
|
||||
allCommands[vcs + ' ' + method] = regex;
|
||||
});
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue