Skip to content

Commit

Permalink
ValueError
Browse files Browse the repository at this point in the history
Signed-off-by: Chris Warrick <kwpolska@gmail.com>
  • Loading branch information
Kwpolska committed Sep 25, 2016
1 parent a021717 commit 9018c37
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions nikola/post.py
Expand Up @@ -188,11 +188,11 @@ def __init__(

if 'title' not in default_metadata or 'slug' not in default_metadata \
or 'date' not in default_metadata:
raise Value("You must set a title (found '{0}'), a slug (found '{1}') and a date (found '{2}')! "
"[in file {3}]".format(default_metadata.get('title', None),
default_metadata.get('slug', None),
default_metadata.get('date', None),
source_path))
raise ValueError("You must set a title (found '{0}'), a slug (found '{1}') and a date (found '{2}')! "
"[in file {3}]".format(default_metadata.get('title', None),
default_metadata.get('slug', None),
default_metadata.get('date', None),
source_path))

if 'type' not in default_metadata:
# default value is 'text'
Expand Down

0 comments on commit 9018c37

Please sign in to comment.