Automattic/sensei

Zero (0) result disappearing in Multiple Choice

Closed this issue · 2 comments

You can't add "0" (zero) result as an answer for a Multiple Choice question, because it is disappearing.

Steps to Reproduce

  1. Go to any lesson and make a quiz for it.
  2. Add a Multiple choice question type.
  3. Add "0" (zero) for answer. (It doesn't matter if it is Right or Wrong.)
  4. Save it (publish) and you can see that "0" answer is disappeared.

PHP / WordPress / Sensei LMS version

PHP 8.1.17
WordPress 6.5.3
Sensei LMS Version: 4.24.0 | Sensei Pro Version: 1.24.0

Screenshot / Video

https://www.loom.com/share/bbdf6936f5d24080a63a59b2c2180dc3?sid=3f0c9a19-a064-434d-b13f-075ff75061ba

I tried it on your instawp demo site:
https://app.instawp.io/launch?t=sensei-lms-demo-site

Confirmed, though a simple workaround is to put a space before or after the 0.