Skip to content

model coffee-script #19

Open
Open
@ghost

Description

Hello, I was start to use restmvc, but when I generate model and I place this code into it

module.exports.test = (mongoose) ->
  schema = mongoose.Schema
  mongoose.model "test", new schema(textValue: String)
  mongoose.model "test"

Then I got:

/home/blizz/Inkubator/TTB/node_modules/restmvc.js/lib/restmvc.js:27
            var model = require(modelsPath + '/' + name)[name](mongoose);
                                                             ^
TypeError: Property 'test.coffee' of object #<Object> is not a function
    at /home/blizz/Inkubator/TTB/node_modules/restmvc.js/lib/restmvc.js:27:62
    at Array.forEach (native)
    at /home/blizz/Inkubator/TTB/node_modules/restmvc.js/lib/restmvc.js:23:15

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions