Skip to content
This repository has been archived by the owner on Dec 12, 2020. It is now read-only.

Application crashes on selecting done with no items within context menus #233

Open
stevendpclark opened this issue Oct 20, 2014 · 1 comment

Comments

@stevendpclark
Copy link
Contributor

Within the Edit Task screen, if you bring up one of the context menus which have no items populated within them and select the Done button the application will crash. Within the application logs you see the following exception.

2014-10-19 23:49:04.401 Todo.txt[8318:244782] Picker: <ActionSheetStringPicker: 0x7fd8fa5c6d70>
2014-10-19 23:49:04.402 Todo.txt[8318:244782] Selected Index: 0
2014-10-19 23:49:04.402 Todo.txt[8318:244782] Selected Value: (null)
2014-10-19 23:49:04.405 Todo.txt[8318:244782] *** Terminating app due to uncaught exception 'NSRangeException', reason: '*** -[__NSArrayI objectAtIndex:]: index 0 beyond bounds for empty array'
*** First throw call stack:
(
    0   CoreFoundation                      0x0000000108ece3f5 __exceptionPreprocess + 165
    1   libobjc.A.dylib                     0x0000000108b37bb7 objc_exception_throw + 45
    2   CoreFoundation                      0x0000000108dc65be -[__NSArrayI objectAtIndex:] + 190
    3   Todo.txt                            0x00000001064e75b7 -[TaskEditViewController projectWasSelected:element:] + 215
    4   Todo.txt                            0x00000001064e8dab __57-[TaskEditViewController keyboardAccessoryButtonPressed:]_block_invoke_2403 + 203
    5   Todo.txt                            0x00000001064d4410 -[ActionSheetStringPicker notifyTarget:didSucceedWithAction:origin:] + 544
    6   Todo.txt                            0x00000001064a9e92 -[AbstractActionSheetPicker actionPickerDone:] + 162
    7   UIKit                               0x00000001075aa9ee -[UIApplication sendAction:to:from:forEvent:] + 75 

This does not happen when you select the Cancel button.

@stevendpclark
Copy link
Contributor Author

Should be resolved with pull request #236

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant