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

Update documentation on what properties are available in the event #88

Open
sephirothmk opened this issue Jul 13, 2018 · 0 comments
Open

Comments

@sephirothmk
Copy link

Initially I didn't know this and made a fork in order to get the data I want from the event, but later I found out that you have the data already available in the event object. Maybe you can update the documentation on the event object to include:

let tableMap = event.tableMap[event.tableId]; tableMap.parentSchema tableMap.tableName event.rows //array, also update event has before and after objects

For example, for the update event im getting the data like this:
event.rows.forEach(function(row) { Object.keys(row.before).forEach(function(name) { if (row.before[name] !== row.after[name]) { dbUpdate.updatedRows.push({[name]: row.after[name]}); } }); });

Would be useful info for new users.

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

1 participant