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

on('end') not being triggered #10

Closed
bahtou opened this issue May 9, 2013 · 1 comment
Closed

on('end') not being triggered #10

bahtou opened this issue May 9, 2013 · 1 comment
Assignees

Comments

@bahtou
Copy link

bahtou commented May 9, 2013

I am reading a csv file and streaming the data through a mongoose.js model.

myFile.js

var stream = fs.createReadStream("name of file"); fcsv(stream) .on('data', function(data) { ModelName.find(query, function(err, docs) { console.log('docs', docs); }); }) .on('end', function() { console.log('done'); }) .parse();

The script runs and a list of docs is printed out.
But the on('end') is not triggered.

What can I do to call the on('end')?

@ghost ghost assigned doug-martin May 9, 2013
@doug-martin
Copy link
Contributor

Is this still an issue in the latest version?

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

2 participants