Skip to content
This repository was archived by the owner on Dec 10, 2019. It is now read-only.

Commit 6693ee2

Browse files
committed
remove speculative alternate pattern data structures
1 parent 82c76ed commit 6693ee2

File tree

2 files changed

+0
-8
lines changed

2 files changed

+0
-8
lines changed

builder/pattern_assembler.js

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,6 @@
3131
function addPattern(pattern, patternlab){
3232
//add the link to the global object
3333
patternlab.data.link[pattern.patternGroup + '-' + pattern.patternName] = '/patterns/' + pattern.patternLink;
34-
if (!patternlab.patternsByKey) { patternlab.patternsByKey = {}; }
35-
if (!patternlab.patternsByAbsPath) { patternlab.patternsByAbsPath = {}; }
3634

3735
//only push to array if the array doesn't contain this pattern
3836
var isNew = true;
@@ -49,8 +47,6 @@
4947
if(isNew){
5048
// do global registration
5149
patternlab.patterns.push(pattern);
52-
patternlab.patternsByKey[pattern.key] = pattern;
53-
patternlab.patternsByAbsPath[pattern.asbpath] = pattern;
5450
// do plugin-specific registration
5551
pattern.registerPartial();
5652
}

builder/patternlab.js

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -128,10 +128,6 @@ var patternlab_engine = function () {
128128
pattern_assembler.process_pattern_recursive(file.substring(2), patternlab);
129129
});
130130

131-
if (patternlab.config.debug) {
132-
console.log('pattern keys:', Object.keys(patternlab.patternsByKey));
133-
console.log('by keys length:', Object.keys(patternlab.patternsByKey).length, 'array length:', patternlab.patterns.length);
134-
}
135131

136132
//delete the contents of config.patterns.public before writing
137133
if(deletePatternDir){

0 commit comments

Comments
 (0)