Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

[geddyjs.org] Bug in the tutorial #515

Closed
krizalys opened this Issue · 1 comment

2 participants

@krizalys

Hello,

There is a syntax error in one of the code snippets published on the geddyjs.org website.

The error is in the section http://geddyjs.org/tutorial#The%20ToDo-side%20of%20the%20association, second snippet, which currently reads:

<h3>Status: <%= toDo.status %></h3>

<h3>Steps</h3>
<% steps.forEach(function (step) { %>
<h4>
  <%- linkTo(step.title, {controller: 'steps', action: 'show', id: step.id}l); %>
</h4>
<% }); %>

Note the l (lowercase "L") at the end of the parameters passed to the linkTo() function. This character causes an error 500 while trying to visit http://localhost:4000/to_dos/:id

This line should be rewritten to something correct like:
<%- linkTo(step.title, {controller: 'steps', action: 'show', id: step.id}); %>

Thanks.

@mde mde referenced this issue from a commit
@mde mde Fixed Issue #515 typo in tutorial 97dd6fe
@mde
Owner

Thanks for catching this. :) Fixed in 97dd6fe on the release branch.

For future reference, the tutorial is in the GitHub repo:

https://github.com/mde/geddy/blob/master/tutorial.md

Feel free to make improvements or corrections there. The Web site pulls from the release branch, so if you have fixes that should go up immediately, just give us a pull request for that branch.

Thanks again!

@mde mde closed this
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.