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

fix: make transaction rejection consistent across dialects #3399

Merged
merged 1 commit into from
Aug 17, 2019

Conversation

thetutlage
Copy link
Contributor

Making mysql and mysql2 dialects use the same sql check as the base transaction class.

sql.toUpperCase() === 'ROLLBACK' &&
t.doNotRejectOnRollback
) {
if (t.doNotRejectOnRollback && /^ROLLBACK\b/i.test(sql)) {
Copy link
Collaborator

Choose a reason for hiding this comment

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

What happens if sql is nil here? It just resolves to false or throw an error?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Returns false

@kibertoad
Copy link
Collaborator

You can pull latest changes from master to resolve oracle test failures.

@kibertoad kibertoad merged commit 831b9bc into knex:master Aug 17, 2019
@kibertoad
Copy link
Collaborator

Thanks! I'll try to publish new release tonight.

@thetutlage
Copy link
Contributor Author

Wow, thanks 😊

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