Problem/Motivation
After content translation removal we need to remove the path for the given translation language.
This happens actually in core/modules/content_translation/src/Form/ContentTranslationDeleteForm, but should happen in path module because if is not there the deletion might not happen, for example using a drush command.
Proposed resolution
Remove the path module check and move that functionality into path.module
Remaining tasks
Task | Novice task? | Contributor instructions | Complete? | |
---|---|---|---|---|
Novice | Instructions | |||
Instructions | ||||
Instructions | ||||
Novice | Instructions |
User interface changes
None.
API changes
Beta phase evaluation
Issue category | Bug because if a translation gets deleted not using the form submit we get an orphan alias |
---|---|
Issue priority | Major because is not he expected result at all. |
Unfrozen changes | Unfrozen because it only moves code to the correct place. |
None.
Comment | File | Size | Author |
---|---|---|---|
#20 | interdiff-2470952-20.txt | 915 bytes | D Szkiba |
#18 | path_deletion_should_be-2470952-18.patch | 2.75 KB | D Szkiba |
#11 | path_deletion_should_be-2470952-11.patch | 1.85 KB | D Szkiba |
Comments
Comment #1
fran seva CreditAttribution: fran seva commentedComment #2
fran seva CreditAttribution: fran seva commentedComment #3
fran seva CreditAttribution: fran seva commentedComment #4
keopxComment #5
fran seva CreditAttribution: fran seva commentedComment #6
D Szkiba CreditAttribution: D Szkiba commentedI work on this on drupal dev days.
Comment #7
bogdan.racz CreditAttribution: bogdan.racz commentedComment #8
bogdan.racz CreditAttribution: bogdan.racz commentedComment #9
D Szkiba CreditAttribution: D Szkiba commentedComment #10
rodrigoaguileraSince this is a normal task is at risk for not being allowed to not be committed in the beta it needs a beta evaluation.
Comment #11
D Szkiba CreditAttribution: D Szkiba commentedMoved the function to path.module. However, this patch still contains the deprecated function getInternalPath so it's not finished yet.
Comment #12
rodrigoaguileraComment #13
rodrigoaguileraAdded more motivation for the change.
While writing it I realized that this is probably a bug since there might be situations where the path is not deleted when the translation is deleted. Any case that doesn't use the form.
We can also write tests for it deleting the translation using code instead of the form.
The code looks ok, only tests letft to do
Comment #14
rodrigoaguileraComment #15
D Szkiba CreditAttribution: D Szkiba commentedThis patch contains only the test.
Comment #16
D Szkiba CreditAttribution: D Szkiba commentedThere is still an error in the test, I'm just posting this to be able to test it with simpletest.
Comment #17
fran seva CreditAttribution: fran seva commentedComment #18
D Szkiba CreditAttribution: D Szkiba commentedThats (hopefully) the final version. "$this" was missing before assertFalse, thx fran for helping!
Comment #19
D Szkiba CreditAttribution: D Szkiba commentedComment #20
D Szkiba CreditAttribution: D Szkiba commentedComment #22
fran seva CreditAttribution: fran seva commentedThe code is good for me.
Comment #23
fran seva CreditAttribution: fran seva commentedComment #24
fran seva CreditAttribution: fran seva commentedComment #25
rodrigoaguileraCode looks great, thanks for working on it.
Comment #26
alexpottCommitted 612581d and pushed to 8.0.x. Thanks!
Thanks for adding the beta evaluation to the issue summary.
Added full stop for coding standards.
Comment #28
Gábor HojtsyThanks!