Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

questionsApiInstance is null after calling questions and reset methods #21

Open
PhilipAngelinNE opened this issue Jul 4, 2023 · 0 comments

Comments

@PhilipAngelinNE
Copy link

PhilipAngelinNE commented Jul 4, 2023

Title. We noticed that after calling the questions method, followed by the reset method, it's crashing as it resets the instance, which means we can't call the questions method again. The stack trace leads here in api.js:

questions: function() {
  return this.questionsApiInstance.questions()
},

The error happens if you do this

item.questions()
item.reset()
item.questions() // Crashes here

And if this is all working as intended, how is one supposed to reset the state of the question, so that a user may retry it, i.e submit a new answer? We're using hints, which is why we're using the questions method, as per your documentation example. Resetting works fine if we don't call the questions method, but then we can't get the hints.

@PhilipAngelinNE PhilipAngelinNE changed the title API instance method "questions" and "getQuestions" are crashing on submitted items questionsApiInstance is null after calling reset method Jul 4, 2023
@PhilipAngelinNE PhilipAngelinNE changed the title questionsApiInstance is null after calling reset method questionsApiInstance is null after calling questions and reset methods Jul 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant