Skip to content

Commit

Permalink
If there is no subdirectory, use POSTS entry instead of '.'
Browse files Browse the repository at this point in the history
Signed-off-by: Chris Warrick <kwpolska@gmail.com>
  • Loading branch information
Kwpolska committed May 2, 2018
1 parent 90bbc98 commit e05e7e9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion nikola/post.py
Expand Up @@ -249,7 +249,7 @@ def __init__(

# Handle CATEGORY_DESTPATH_AS_DEFAULT
if 'category' not in meta and self.config['CATEGORY_DESTPATH_AS_DEFAULT']:
if self.config['CATEGORY_DESTPATH_TRIM_PREFIX']:
if self.config['CATEGORY_DESTPATH_TRIM_PREFIX'] and self.folder_relative != '.':
category = self.folder_relative
else:
category = self.folders[lang]
Expand Down

0 comments on commit e05e7e9

Please sign in to comment.