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

Delete relations when disabling dp on a content type #9878

Merged
merged 1 commit into from
Dec 2, 2021

Conversation

petersg83
Copy link
Contributor

@petersg83 petersg83 commented Mar 30, 2021

I think we can create a function deleteRelationsWhere to avoid copy-pasting the same logic. However, as it will all change soon, it may not be worth spending time on it. What do you think ?

Also this PR is based on features/i18n, it could be on master. What do you prefer?

EDIT: base branch changed to releases/v3.6.9

@codecov
Copy link

codecov bot commented Mar 30, 2021

Codecov Report

Merging #9878 (890c5b6) into features/i18n (1daf792) will increase coverage by 1.54%.
The diff coverage is 77.88%.

❗ Current head 890c5b6 differs from pull request most recent head 49f07d9. Consider uploading reports for the commit 49f07d9 to get more accurate results
Impacted file tree graph

@@                Coverage Diff                @@
##           features/i18n    #9878      +/-   ##
=================================================
+ Coverage          57.19%   58.74%   +1.54%     
=================================================
  Files                153      178      +25     
  Lines               4670     5497     +827     
  Branches             919     1030     +111     
=================================================
+ Hits                2671     3229     +558     
- Misses              1579     1811     +232     
- Partials             420      457      +37     
Flag Coverage Δ
front ∅ <ø> (∅)
unit 58.74% <77.88%> (+1.54%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
...ackages/strapi-admin/validation/action-provider.js 85.71% <ø> (ø)
...i-database/lib/queries/relations-counts-queries.js 29.16% <12.50%> (+3.07%) ⬆️
...n/services/permission/sections-builder/handlers.js 23.07% <23.07%> (ø)
...in/services/permission/sections-builder/builder.js 40.00% <40.00%> (ø)
packages/strapi-admin/controllers/role.js 50.00% <42.30%> (+2.83%) ⬆️
packages/strapi-admin/validation/permission.js 78.43% <50.00%> (+0.43%) ⬆️
packages/strapi-admin/controllers/permission.js 70.58% <55.55%> (-4.42%) ⬇️
...ckages/strapi-admin/services/permission/queries.js 69.69% <69.69%> (ø)
...kages/strapi-admin/validation/common-validators.js 84.37% <81.39%> (-4.92%) ⬇️
...dmin/services/permission/sections-builder/index.js 86.66% <86.66%> (ø)
... and 61 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 f3fe056...49f07d9. Read the comment docs.

Base automatically changed from features/i18n to master April 21, 2021 15:00
@petersg83 petersg83 changed the base branch from master to releases/v3.6.9 December 2, 2021 09:21
@petersg83
Copy link
Contributor Author

@alexandrebodin just tried it with sqlite and mongo and it works well

@alexandrebodin alexandrebodin added this to the 3.6.9 milestone Dec 2, 2021
@alexandrebodin alexandrebodin added source: core:content-manager Source is core/content-manager package issue: bug Issue reporting a bug labels Dec 2, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
issue: bug Issue reporting a bug source: core:content-manager Source is core/content-manager package
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants