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

Aliases deletion #9933

Merged
merged 6 commits into from Sep 19, 2018
Merged

Aliases deletion #9933

merged 6 commits into from Sep 19, 2018

Conversation

@frlinw
Copy link
Contributor

@frlinw frlinw commented Sep 18, 2018

Pull Request check-list

Please make sure to review and check all of these items:

  • Does npm run test or npm run test-DIALECT pass with this change (including linting)?
  • Does the description below contain a link to an existing issue (Closes #[issue]) or a description of the issue you are solving?
  • Is a documentation update included (if this change modifies existing APIs, or introduces new ones)?
  • Did you follow the commit message conventions explained in CONTRIBUTING.md?

Description of change

Remove some aliases
#9372

List of aliases

Remove Keep
insertOrUpdate upsert ✔️
find findOne ✔️
findAndCount findAndCountAll ✔️
findOrInitialize findOrBuild ✔️
beforeConnection beforeConnect ✔️
[after,before]BulkDelete [after,before]BulkDestroy ✔️
[after,before]Delete [after,before]Destroy ✔️
hook addHook ✔️
updateAttributes update ✔️
asIs literal ✔️
Sequelize.condition Sequelize.where ✔️
Sequelize.prototype.Utils Sequelize.Utils ✔️
Sequelize.prototype.Promise Sequelize.Promise ✔️
Sequelize.prototype.TableHints Sequelize.TableHints ✔️
Sequelize.prototype.Op Sequelize.Op ✔️
Sequelize.prototype.Transaction Sequelize.Transaction ✔️
Sequelize.prototype.Model Sequelize.Model ✔️
Sequelize.prototype.Deferrable Sequelize.Deferrable ✔️
Sequelize.prototype.Error Sequelize.Error ✔️
Sequelize.prototype[error] Sequelize[error] ✔️

Particular case

Remove New
findById, findByPrimary findByPk ✔️

DataTypes

I tried to make DOUBLE PRECISION change but this caused tests failure and I was unable to fix them. So I left DOUBLE PRECISION & NUMERIC aliases unchanged.

Remove Keep
NONE VIRTUAL ✔️
DOUBLE PRECISION DOUBLE
NUMERIC DECIMAL
@frlinw
Copy link
Contributor Author

@frlinw frlinw commented Sep 18, 2018

Tests fixed. Don't know why codecov failed.

Copy link
Contributor

@sushantdhiman sushantdhiman left a comment

Just one small change otherwise LGTM

@@ -1,7 +1,7 @@
'use strict';

This comment has been minimized.

@sushantdhiman

sushantdhiman Sep 19, 2018
Contributor

Only case for SequelizeErrors is changed, remove changes from this file

This comment has been minimized.

@frlinw

frlinw Sep 19, 2018
Author Contributor

It was for consistancy, it's the only file where sequelizeErrors is used with an upper first letter. I'm reverting.

This comment has been minimized.

@sushantdhiman

sushantdhiman Sep 19, 2018
Contributor

Leave it

@sushantdhiman
Copy link
Contributor

@sushantdhiman sushantdhiman commented Sep 19, 2018

Code coverage can be ignored for this PR

@codecov
Copy link

@codecov codecov bot commented Sep 19, 2018

Codecov Report

Merging #9933 into master will decrease coverage by <.01%.
The diff coverage is 82.75%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #9933      +/-   ##
==========================================
- Coverage   96.04%   96.04%   -0.01%     
==========================================
  Files          63       63              
  Lines        9431     9420      -11     
==========================================
- Hits         9058     9047      -11     
  Misses        373      373
Impacted Files Coverage Δ
lib/dialects/postgres/query-generator.js 93.46% <ø> (ø) ⬆️
lib/errors/index.js 100% <ø> (ø) ⬆️
lib/associations/mixin.js 100% <ø> (ø) ⬆️
lib/dialects/postgres/query-interface.js 100% <ø> (ø) ⬆️
lib/data-types.js 95.75% <ø> (ø) ⬆️
lib/utils.js 98.29% <ø> (ø) ⬆️
lib/dialects/mysql/query-generator.js 97.77% <ø> (ø) ⬆️
lib/associations/belongs-to.js 100% <100%> (ø) ⬆️
lib/sequelize.js 96.57% <100%> (ø) ⬆️
lib/dialects/abstract/query-generator.js 97.64% <100%> (ø) ⬆️
... and 4 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update aa92764...6a659c0. Read the comment docs.

@sushantdhiman sushantdhiman merged commit b37985d into sequelize:master Sep 19, 2018
2 of 4 checks passed
2 of 4 checks passed
codecov/patch 82.75% of diff hit (target 96.04%)
Details
codecov/project 96.04% (-0.01%) compared to aa92764
Details
continuous-integration/appveyor/pr AppVeyor build succeeded
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
@sushantdhiman sushantdhiman mentioned this pull request Sep 19, 2018
0 of 5 tasks complete
@sushantdhiman
Copy link
Contributor

@sushantdhiman sushantdhiman commented Sep 19, 2018

Thanks @frlinw

@SimonSchick
Copy link
Member

@SimonSchick SimonSchick commented Sep 19, 2018

TY, this should make future development much less confusing!

@frlinw frlinw mentioned this pull request Oct 1, 2018
4 of 4 tasks complete
@SimonSchick
Copy link
Member

@SimonSchick SimonSchick commented Oct 6, 2018

@sushantdhiman @frlinw you missed hasHooks vs. hasHook 🙂

@frlinw
Copy link
Contributor Author

@frlinw frlinw commented Oct 7, 2018

@SimonSchick it was a request from sushantdhiman #9372 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

3 participants