Integrate suggestions from code review

This commit is contained in:
Neale Pickett 2016-11-17 14:24:01 -07:00
parent 5128a72842
commit 1f1f41a696
2 changed files with 2 additions and 1 deletions

View File

@ -128,7 +128,7 @@ you are a fool.
if fpath:
cat = moth.Category(fpath, seed)
if points:
puzzle = cat.puzzle(int(parts[3]))
puzzle = cat.puzzle(points)
if not cat:
title = "Puzzle Categories"

View File

@ -181,6 +181,7 @@ class Category:
self.catmod = importlib.machinery.SourceFileLoader(
'catmod',
os.path.join(path, 'category.py')).load_module()
self.pointvals.extend(self.catmod.points)
self.pointvals = self.catmod.points[:]
else:
for fpath in glob.glob(os.path.join(path, "[0-9]*")):