Skip to content

Commit

Permalink
Add docstrings and rename a function
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 7, 2016
1 parent 2ce1c52 commit 3693bfe
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion nikola/plugins/command/install_theme.py
Expand Up @@ -88,4 +88,4 @@ def _execute(self, options, args):
if listing:
p.list_available(url)
else:
p.do_install_loop(url, name)
p.do_install_deps(url, name)
6 changes: 4 additions & 2 deletions nikola/plugins/command/theme.py
Expand Up @@ -118,11 +118,12 @@ def _execute(self, options, args):
elif uninstall:
return self.do_uninstall(uninstall)
elif install:
return self.do_install_loop(url, install)
return self.do_install_deps(url, install)
elif get_path:
return self.get_path(get_path)

def do_install_loop(self, url, name):
def do_install_deps(self, url, name):
"""Install themes and their dependencies."""
data = self.get_json(url)
# `name` may be modified by the while loop.
origname = name
Expand Down Expand Up @@ -184,6 +185,7 @@ def do_install(self, name, data):
return True

def do_uninstall(self, name):
"""Uninstall a theme."""
try:
path = utils.get_theme_path(name)
except Exception:
Expand Down

0 comments on commit 3693bfe

Please sign in to comment.