Skip to content

Meteor 1.7: client side error TypeError: Class constructor Dependency cannot be invoked without 'new' #84

@nzomedia

Description

@nzomedia

Hi, first, thank you for making meteor-mysql.

I've just upgraded Meteor from 1.6.1.1 to 1.7.0.5, and as you may have noticed, Meteor uses a new aproche where it can use packages as es6 or es5 depending on the client browser capabilities.

The problem i'm having actually is that i'm using a modern browser (Chrome Version 63.0.3239.132 (Build officiel) (64 bits)), and when i try to access the app with my browser, i get an error in the console:

Uncaught TypeError: Class constructor Dependency cannot be invoked without 'new'

in numtel_mysql.js at line 67

And my app doesn't work.
To me it seems that Meteor isn't compilling the tracker.js to ES5 so that class Tracker.Dependency can be used as a Js constructor function. Therefore at line 67 in numtel_mysql.js, Tracker.Dependency.call(..) doesn't work anymore and should something like new Tracker.Dependency(...) instead.

Actually i don't fully understand how to configure Meteor's new way of managing modules, but i thought it would be benefic to anyone using the package to rise this issue. Perhapse juste modifying the file at line 67 could make things work again, i'll keep searching. Until then If anyone has a solution to make numtel work again with Meteor 1.7 please share it.

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