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

Fix duplicate checkbox ID issue #1

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

WTC-Tarik-C-W
Copy link

I've noticed that since the generateID() function generates ID numbers based on the number of items currently in the list, that you can generate tasks whose checkboxes have the same ID.
You can do this by adding multiple tasks, then deleting one or more tasks that aren't the last one, then adding more tasks.
This results in some labels being linked to the wrong checkbox and the incorrect checkbox being toggled when their label is clicked.
This issue has been fixed by making the generateID() function check the ID of the last task on the list and generate one that is one number higher.

I've noticed that since the generateID() function generates ID numbers based on the number of items currently in the list, that you can generate tasks whose checkboxes have the same ID.
You can do this by adding multiple tasks, then deleting one or more tasks that aren't the last one, then adding more tasks.
This results in some labels being linked to the wrong checkbox and the incorrect checkbox being toggled when their label is clicked.
This issue has been fixed by making the generateID() function check the ID of the last task on the list and generate one that is one number higher.
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

Successfully merging this pull request may close these issues.

1 participant