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

Reduction of count from the collection #120

Open
musriabhijit opened this issue Nov 30, 2016 · 3 comments
Open

Reduction of count from the collection #120

musriabhijit opened this issue Nov 30, 2016 · 3 comments
Labels

Comments

@musriabhijit
Copy link

musriabhijit commented Nov 30, 2016

@ocram
when we subscribe to the endpoint with unique id, after subscription the unique id document data is removed from the particular collection

eg :mMeteor.subscribe("user.id", userID);
the above userID document is removed from the particular collection Database

@ocram ocram added the question label Nov 30, 2016
@ocram
Copy link
Contributor

ocram commented Nov 30, 2016

If you call

mMeteor.subscribe("user.id", userID);

then it will subscribe to data from the server, unless you didn't publish something called user.id on the server. Use the listener with the optional parameter (see README) to check if the subscription succeeds or not. If it does, you will get additional data from the server.

Please insert log statements in onDataAdded, onDataChanged and onDataRemoved to see what's actually happening there. This way, you can precisely track down what's being added and removed and why that's happening.

@musriabhijit
Copy link
Author

musriabhijit commented Dec 1, 2016

my question is the document from the collection get removed when i subscribe to a particular element in other activity and in when i come back to same activity the particular document in the collection gets removed

@ocram
Copy link
Contributor

ocram commented Jan 15, 2017

Can you provide any specific (step-by-step) description of how to re-produce this? Perhaps even with a minimum code example. Otherwise, we can't re-produce this right now and have never heard about that problem, so we'd close this until there is more evidence.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants