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

Implementation of Indexes and Compacting #18

Open
wants to merge 29 commits into
base: master
Choose a base branch
from

Conversation

pathsny
Copy link

@pathsny pathsny commented Apr 21, 2011

Hi
I've made some changes to node-dirty (for my own purpose mainly). But Im hoping you can pull it in so it changes what npm provides :)

@felixge
Copy link
Owner

felixge commented Apr 22, 2011

Looks very interesting. Any reason you didn't add a callback to 'compact'? This would remove the need for the two additional events.

@pathsny
Copy link
Author

pathsny commented Apr 22, 2011

Hmm not really. I was just trying to figure out the node way. In this case
do I think a callback is better. I used events to prevent nesting, nothing
more.

Btw I had introduced a subtle bug. I've fixed it in the commit after the
pull request I think.

On 22 Apr 2011 18:38, "felixge" <
[email protected]>
wrote:

Looks very interesting. Any reason you didn't add a callback to 'compact'?
This would remove the need for the two additional events.

Reply to this email directly or view it on GitHub:
#18 (comment)

@felixge
Copy link
Owner

felixge commented Apr 23, 2011

How are events preventing nesting?

@pathsny
Copy link
Author

pathsny commented Apr 23, 2011

Hi felix,
I just meant that calls to compact need not include a function (which
would typically be nested). But this would typically be solvable using a
named function.

The truth is, until I try to build.something that is gonna act on the
information of whether the compact failed or suceeded, I'm not sure which
api is easier to consume. I ended up consuming the events internally, so I
let them remain something available externally too.

This could have just as well been done by passing a callback around though,
both inside node dirty and outside.

On 23 Apr 2011 16:03, "felixge" <
[email protected]>
wrote:

How are events preventing nesting?

Reply to this email directly or view it on GitHub:
#18 (comment)

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

Successfully merging this pull request may close these issues.

3 participants