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

feat: show new events and fetch correctly #650

Merged
merged 2 commits into from
Nov 8, 2018

Conversation

nicosantangelo
Copy link
Contributor

It's not trying to be 100% complete with the descriptions

Copy link
Contributor

@nachomazzara nachomazzara left a comment

Choose a reason for hiding this comment

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

LGTM

Just one coment

const blockchainEvents = await BlockchainEvent.findByArgs(
'assetId',
const blockchainEvents = await BlockchainEvent.findByAnyArgs(
['assetId', 'landId', '_landId', '_estateId'],
Copy link
Contributor

Choose a reason for hiding this comment

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

Also we have _tokenId for the ERC721 Transfer event

@@ -290,7 +304,7 @@ const main = {
const asset = await getAssetFromCLIArgs(assetId, assetType)

const events = await BlockchainEvent.findByAnyArgs(
['assetId', '_landId'],
['assetId', 'landId', '_landId', '_estateId'],
Copy link
Contributor

Choose a reason for hiding this comment

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

Maybe we could add also _tokenId

Copy link
Contributor

@nachomazzara nachomazzara Nov 7, 2018

Choose a reason for hiding this comment

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

Hmm What do you think of using something like:

const argsId = ['assetId', 'landId', '_landId', '_estateId', '_tokenId']

we have the same in two places in the same file

IDK a good name: argsId, wordToMatchId, matchId, argsNames

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Agree with abstracting this!

@nicosantangelo
Copy link
Contributor Author

Updated! let me know what you think of the constant name! (POSSIBLE_ASSET_EVENT_IDS)

@nachomazzara
Copy link
Contributor

giphy

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.

2 participants