-
Notifications
You must be signed in to change notification settings - Fork 12
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
Channel queues flowtyped #64
base: master
Are you sure you want to change the base?
Conversation
* @param {Number} version - version of ghost data | ||
* @param {Object} data - object literal to save as this ghost's data for this version | ||
* @returns {Promise<Ghost>} - the ghost for this object | ||
*/ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what's going on here? are these missing or is the JSDoc comment supposed to indicate that the functions exist?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The functions appear to be missing. I think this is the only Flow typed file that tries to use a GhostStore
and the only method it needs is GhostStore.get
.
Once this interface
is moved to the proper location (a Flow typed Bucket
or Channel
module perhaps) the missing interface methods would have failed the type checker.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ha, I event wrote as much over a year ago:
The GhostStore type is currently located in the LocalQueue module because it is the only one using that type definition at this moment. It will need a better home when the Channel module gets flowtyped but I think we can cross that bridge when we tackle the Channel changes.
Extracts and flowtypes the
Queue
classes fromChannel
.No application logic is changed other than adding some null checks where flow complains (rightfully so).
The
GhostStore
type is currently located in theLocalQueue
module because it is the only one using that type definition at this moment. It will need a better home when theChannel
module gets flowtyped but I think we can cross that bridge when we tackle theChannel
changes.