Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Correctly deal with no row selection

  • Loading branch information...
commit 0fa06728b954fe372187af75728fc01f52d1051b 1 parent 7c9f847
@beelsebob authored
Showing with 2 additions and 2 deletions.
  1. +2 −2 Stash/STAMainWindowController.m
View
4 Stash/STAMainWindowController.m
@@ -264,8 +264,8 @@ - (NSInteger)numberOfRowsInTableView:(NSTableView *)tableView
- (void)tableViewSelectionDidChange:(NSNotification *)notification
{
- NSUInteger row = [[self resultsTable] selectedRow];
- if (row < [[self sortedResults] count])
+ NSInteger row = [[self resultsTable] selectedRow];
+ if (row < [[self sortedResults] count] && row != -1)
{
STASymbol *symbol = [[self sortedResults] objectAtIndex:row];
NSURLRequest *request = [NSURLRequest requestWithURL:[symbol url]];
Please sign in to comment.
Something went wrong with that request. Please try again.