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

Add comments and refactor style #59

Closed
wants to merge 1 commit into from

Conversation

dmsnell
Copy link
Contributor

@dmsnell dmsnell commented Feb 19, 2018

While working on tracking down a nasty synchronization bug
I could keep all the data flows and puzzle pieces together
in my mind, so I wrote some of them down as best as I was
understanding them.

Further I refactored some code because I find the terser
styles afforded by ES2015+ syntax to confuse me less,
especially when following around closures with bind and
call and apply

The point isn't to change behaviors here but to figure them
out and write them down. That is, there should be no
functional changes in this patch and if there are then it's
probably a bug.

While working on tracking down a nasty synchronization bug
I could keep all the data flows and puzzle pieces together
in my mind, so I wrote some of them down as best as I was
understanding them.

Further I refactored some code because I find the terser
styles afforded by ES2015+ syntax to confuse me less,
especially when following around closures with `bind` and
`call` and `apply`
@@ -47,6 +54,7 @@ internal.buildModifyChange = function( id, object, ghost ) {
}

if ( empty ) return this.emit( 'unmodified', id, object, ghost );
payload.v && payload.v.content && console.log(payload.v.content)
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oops will take this out - part of my investigation

return update.call( bucket, id, object, options, function( err, object ) {
console.timeEnd('update')
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

will remove

@beaucollins
Copy link
Contributor

I've been exploring flowtype for this project and have cleaned up the Channel module quite a bit while experimenting. Take a look at #60 to see a much better documented and cleaner interface for src/simperium/channel.js

@dmsnell
Copy link
Contributor Author

dmsnell commented May 1, 2018

Not enough time to rebase this and update it. It was a helpful exploration and hopefully it will happen again in the future.

@dmsnell dmsnell closed this May 1, 2018
@dmsnell dmsnell deleted the refactor/add-comments-and-update-style branch May 1, 2018 10:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants