Skip to content

@resource and @collection throw errors in views #19

@ghost

Description

Right now the following order generates errors (with all the dependencies installed):
./script/generate dscaffold Duck name:string about:text _actions:new,create,index,quack

The errors are:

  1. On apps/views/duck/index.html.haml
    @collection.each do |resource| #gives an error (@collection is nil)
  2. On apps/views/duck/new.html.haml
    semantic_form_for(@resource) do |form| #gives an error (@resource is nil)

I believe the second error will also happen on edit - I just didn't generate a view for the action.

If I change @collection and @resource to @ducks and @duck the errors go away.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions