Minor style changes.

This commit is contained in:
Michael Lazar
2016-07-20 21:28:24 -07:00
parent 323ff65dfd
commit 9cfa44c726
4 changed files with 8 additions and 8 deletions

View File

@@ -39,7 +39,7 @@ HELP = """
`l` or `RIGHT` : Enter the selected submission
`/` : Open a prompt to switch subreddits
`f` : Open a prompt to search the current subreddit
'p' : Toggles between FrontPage and last visited subreddit
'p' : Toggle between the front page and last visited subreddit
[Submission Mode]
`h` or `LEFT` : Return to subreddit mode

View File

@@ -77,20 +77,19 @@ class SubredditPage(Page):
@SubredditController.register(Command('SUBREDDIT_FRONTPAGE'))
def show_frontpage(self):
"""
If on a subreddit, remeber it and head back to the front page.
If on a subreddit, remember it and head back to the front page.
If this was pressed on the front page, go back to the last subreddit.
"""
target =''
if not self.content.name == '/r/front':
target = '/r/front'
self._toggled_subreddit = self.content.name
else:
target = self._toggled_subreddit
# target still may be emptystring if this command hasn't yet been used
if not target == None:
self.refresh_content(order='ignore',name=target)
# target still may be empty string if this command hasn't yet been used
if target is not None:
self.refresh_content(order='ignore', name=target)
@SubredditController.register(Command('SUBREDDIT_OPEN'))
def open_submission(self, url=None):