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

Set correct value (false) for CKFinderCommand#affectsData #13214

Merged
merged 2 commits into from
Jan 9, 2023

Conversation

kbinieda
Copy link
Contributor

@kbinieda kbinieda commented Jan 4, 2023

Suggested merge commit message (convention)

Feature (track-changes): Add track changes integration for CKFinder feature.

Other (ckfinder): Set correct value (false) for CKFinderCommand#affectsData. Now the command's state depends only on related commands (insertImage and link). Closes #13213.

@kbinieda kbinieda requested a review from scofalik January 4, 2023 21:20
@scofalik scofalik changed the title Feature (ckfinder): Make ckfinder enabled for track changes Internal (ckfinder): Set correct value (false) for CKFinderCommand#affectsData Jan 5, 2023
@scofalik scofalik changed the title Internal (ckfinder): Set correct value (false) for CKFinderCommand#affectsData Set correct value (false) for CKFinderCommand#affectsData Jan 5, 2023
Copy link
Contributor

@scofalik scofalik left a comment

Choose a reason for hiding this comment

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

I am missing any test checking this value. I wanted to propose to check if the command is enabled in read only mode but it would be disabled anyway as link and image are disabled in this mode. So, I guess, we need to check directly affectsData.

@kbinieda
Copy link
Contributor Author

kbinieda commented Jan 8, 2023

I am missing any test checking this value. I wanted to propose to check if the command is enabled in read only mode but it would be disabled anyway as link and image are disabled in this mode. So, I guess, we need to check directly affectsData.

I've added the test although, since the change does not introduce any behaviour (it's just a configuration preset) IMHO I don't think it needs testing.

@kbinieda kbinieda requested a review from scofalik January 8, 2023 10:53
@scofalik
Copy link
Contributor

scofalik commented Jan 9, 2023

I know this test is weak. We could come up with some artificial tests that checks it though -- after all, we are adding this property with some purpose in mind. This change fixes situation in track changes after all, so there's a scenario for it. But I am not a fan of such test as well. We should add a test in track changes checking whether CKF is properly enabled.

@scofalik scofalik merged commit 1b95b17 into master Jan 9, 2023
@scofalik scofalik deleted the ck/13213-ckfinder-track-changes branch January 9, 2023 12:20
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.

Make CKFinder work with track changes.
2 participants