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

renderElement TypeError when backend doesn't exist #29

Closed
ricopicone opened this issue Feb 14, 2022 · 5 comments
Closed

renderElement TypeError when backend doesn't exist #29

ricopicone opened this issue Feb 14, 2022 · 5 comments

Comments

@ricopicone
Copy link
Contributor

I'm getting the following error.
image

I'm using URLSearchParams like that visible in the error, ?TS=T1&DS=, and it seems this might be where the trouble lies. Interestingly, the algorithm still renders properly.

Any ideas?

@ricopicone
Copy link
Contributor Author

Sorry, the obscured part reads read properties of undefined (reading 'name') at Object.renderElement

@ricopicone
Copy link
Contributor Author

Update: only the first algorithm to appear on the page renders properly, which makes sense because it looks like it's an error in a for loop.

ricopicone added a commit to ricopicone/pseudocode.js that referenced this issue Feb 19, 2022
@ricopicone ricopicone changed the title renderElement TypeError with URLSearchParams renderElement TypeError when backend doesn't exist Feb 19, 2022
@ricopicone
Copy link
Contributor Author

The PR above fixes the issue, which in the end had nothing to do with the url search parameters. Rather, no renderer.backend existed, so renderer.backend.name gave the error.

@SaswatPadhi
Copy link
Owner

Many thanks for debugging this issue and for the PR!

@ricopicone
Copy link
Contributor Author

My pleasure!

SaswatPadhi pushed a commit that referenced this issue Mar 6, 2022
* fixes #29 by adding a check that the backend exists before getting its name

* needed npm install and make setup does not exist
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

2 participants