Skip to content

Commit

Permalink
Merge pull request #3159 from getnikola/fix-3150
Browse files Browse the repository at this point in the history
Fix #3150
  • Loading branch information
Kwpolska committed Sep 7, 2018
2 parents 29fab6d + 3d03158 commit 473f7b6
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
1 change: 1 addition & 0 deletions CHANGES.txt
Expand Up @@ -57,6 +57,7 @@ Features
Bugfixes
--------

* Pass arguments to youtube directive unchanged (Issue #3150)
* Fix listing installed themes if theme directory is missing.
* Watch correct output folder in ``nikola auto`` (Issue #3119)
* Fix post fragment dependencies when posts are only available in a
Expand Down
6 changes: 3 additions & 3 deletions nikola/plugins/compile/rest/youtube.py
Expand Up @@ -67,8 +67,8 @@ class Youtube(Directive):
has_content = True
required_arguments = 1
option_spec = {
"width": directives.positive_int,
"height": directives.positive_int,
"width": directives.unchanged,
"height": directives.unchanged,
"align": _align_choice
}

Expand All @@ -80,7 +80,7 @@ def run(self):
'width': 560,
'height': 315,
}
options.update(self.options)
options.update({k: v for k, v in self.options.items() if v})
if self.options.get('align') in _align_options_base:
options['align'] = ' align-' + self.options['align']
else:
Expand Down

2 comments on commit 473f7b6

@python-friends
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @Kwpolska, Thanks for fixing this! I've been away and was just about to submit a PR when I noticed the issue was closed. At least I got to read about docutils parser directives ;)

@Kwpolska
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(@ralsina wrote the code, I just pushed the Merge button.)

Please sign in to comment.