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
Problem with collection Metor.users #13
Comments
Thanks @kjm I believe @rclai is working on a fix for this, see here; reactioncommerce/meteor-security#8 (comment) |
What is the error? Is it the same as above? |
@rclai Yes, it's throwing the error here: if (!(options.collection instanceof Mongo.Collection)) {
throw new Error('Tabular.Table options must specify collection');
} |
Is Tabular.Table a third-party package? Which one is it? |
Yes, it's a 3rd party package located here: https://github.com/aldeed/meteor-tabular |
What is your list of packages in the .versions file? |
accounts-base@1.2.0 |
But I can reproduce it on a vanilla installation of Meteor with only the following in .meteor/packages: dburles:mongo-collection-instances |
In the above vanilla installation: if (Meteor.isClient) {
console.log(Meteor.users instanceof Mongo.Collection); // <----- false for IE 9/10, true for IE 11
} |
Ah okay that's good. I can check that out. I'll keep you posted. |
@dkoo761 in your app, can you git clone to your local |
Wait, hold your horses, I messed up something. |
@dkoo761 okay, try it now. |
@rclai sorry for the delayed reply, I implemented a workaround then got busy with some other stuff. It appears that this actually made it worse. The server won't even start up now as I'm getting the error: "Error: Tabular.Table options must specify collection" for the Meteor.users collection. I git cloned as you asked and named the directory collection-extensions-ie9-fix under /packages. I didn't alter my .packages or .versions file. Do I need to? |
If I comment out your new CollectionExtensions._reassignCollectionPrototype and replace it with the previous commit's version then the app at least starts up again so it does look like something specific to this last commit. Perhaps this polyfill will help? https://gist.github.com/WebReflection/5593554 |
Yeah, I figured it didn't work. I think I tried that polyfill too, but I'm not sure, if you just locally change it to use the polyfill would it work? |
I tried using the polyfill locally and that fixed the startup error but no still no luck with IE9/10 as the polyfill function returns before it does anything useful. |
Hi,
It's good idea to have such functionality, thx.
There's a problem with collection served automatically - Meteor.users (by Accounts package).
After install mongo-collection-instances this one collection is no more instanceof Mongo.collection.
This causes that tests like below fails
if (!(options.collection instanceof Mongo.Collection)) {
throw new Error('Tabular.Table options must specify collection');
}
or
console.log(Meteor.users instanceof Mongo.Collection); ->> false
console.log( instanceof Mongo.Collection); ->> true
Any tips how to resolve this? :)
Best regards
Konrad
The text was updated successfully, but these errors were encountered: