Footnote icon indicating copy to clipboard operation
Footnote copied to clipboard

App crashes when no Quotes exist in Core Data

Open Yonodactyl opened this issue 4 years ago • 1 comments

Describe the bug When you open the app for the first time and go into the settings section and tap export to json the application crashes. The error mentioned:

2020-11-06 21:27:10.719121-0500 Footnote[85377:1996263]
*** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason:
'+entityForName: nil is not a legal NSPersistentStoreCoordinator for searching for entity name 'Quote''

To Reproduce Steps to reproduce the behavior:

  1. Open the app for the first time.
  2. Don't add any quotes.
  3. Open settings.
  4. Export to json

Expected behavior Here I would expect an alert saying that there are no quotes to export. I could also see the button being grayed out/disabled because there is nothing in the core data stack.

Smartphone (please complete the following information):

  • Device: Simulator
  • OS: 13.0
  • Version 1.03

Yonodactyl avatar Nov 07 '20 02:11 Yonodactyl

Hi, shall I fix this? @cambardell

JapneetSingh5 avatar Nov 12 '20 11:11 JapneetSingh5