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

routes is not a function if model has "routes" attribute #118

Open
throrin19 opened this issue Jun 3, 2019 · 0 comments
Open

routes is not a function if model has "routes" attribute #118

throrin19 opened this issue Jun 3, 2019 · 0 comments

Comments

@throrin19
Copy link
Contributor

I think the library has a problem, depends on the model attributes we have. For example, I Have this model :

{
  id : 1,
  name : 'test',
  routes : []
}

With this attribute routes, I have the specific error if I try to launch a fetch, save or delete :

TypeError: this.routes is not a function
    at DatabaseMachineModel.getRoute (vue-mc.es.js:731)
    at DatabaseMachineModel.getDeleteRoute (vue-mc.es.js:591)
    at DatabaseMachineModel.getDeleteURL (vue-mc.es.js:764)

I think, the problem is with all specifics fields with model functions names. Try with, for example, a model with the attribute request and you crash all the model.

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

1 participant