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

Bug fix in Array2dTracer _notify () #98

Merged
merged 1 commit into from May 28, 2016
Merged

Bug fix in Array2dTracer _notify () #98

merged 1 commit into from May 28, 2016

Conversation

duaraghav8
Copy link
Member

@duaraghav8 duaraghav8 commented May 28, 2016

First, check out this scratch

When I use _notify () function on 2D Array Tracer with 3rd argument (v) as 0, the value in tracer is not updated even though 0 is a perfectly valid value.

This is because line 133 of array2d.js says:

if (step.v) {...}

This disqualifies 0, and doesn't allow us to set it as any item's value. We need to dis-allow all false-equivalent values apart from 0.
I think we should even allow null, but I haven't fixed for that, only for 0.

The result is as expected on my ghpages

@64json 64json merged commit 67db2a0 into algorithm-visualizer:gh-pages May 28, 2016
@TornjV TornjV mentioned this pull request May 28, 2016
64json added a commit that referenced this pull request Jul 24, 2018
Bug fix in Array2dTracer _notify ()
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.

None yet

2 participants