Navigation Menu

Skip to content

Commit

Permalink
fix getnikola/nikola#1612 -- get gallery index sanely
Browse files Browse the repository at this point in the history
Signed-off-by: Chris Warrick <kwpolska@gmail.com>
  • Loading branch information
Kwpolska committed Feb 8, 2015
1 parent ba6a22f commit 91a50cd
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions v6/gallery_directive/gallery_directive.py
Expand Up @@ -63,11 +63,9 @@ def run(self):
gallery_name = self.arguments[0]
kw = {
'output_folder': self.site.config['OUTPUT_FOLDER'],
'gallery_path': self.site.config['GALLERY_PATH'],
'thumbnail_size': self.site.config['THUMBNAIL_SIZE'],
}
gallery_folder = os.path.join(kw['output_folder'], kw['gallery_path'], gallery_name)
gallery_index = os.path.join(gallery_folder, 'index.html')
gallery_index = self.site.path('gallery', gallery_name)
self.state.document.settings.record_dependencies.add(gallery_index)
with open(gallery_index, 'r') as inf:
data = inf.read()
Expand Down

0 comments on commit 91a50cd

Please sign in to comment.