stable

Clone or download

Read-only

Remove uneeded object LockChecker and Rely on core mechanism

part of story #12454 Lock documents PATCH routes relies on wrong mechnism, we should not try to be smart and directly rely on core: - Admin can now release any lock - Regular user has a not allowed error, if they try to unlock file locked by anybody else History is still not recorded at this step, I will do it in a dedicated commit Change-Id: I08930c315224979fce25e0e5828b4fa83fa8f50b

Modified Files

Name
M plugins/docman/include/Docman_LockFactory.class.php +7 −10 Go to diff View file
M plugins/docman/include/Docman_PermissionsManager.class.php +5 −4 Go to diff View file
D plugins/docman/include/Lock/LockChecker.php +0 −50 Go to diff View file
M plugins/docman/include/REST/v1/DocmanEmbeddedFilesResource.php +5 −14 Go to diff View file
M plugins/docman/include/REST/v1/DocmanFilesResource.php +10 −23 Go to diff View file
M plugins/docman/include/REST/v1/DocmanItemUpdator.php +0 −9 Go to diff View file
M plugins/docman/include/REST/v1/DocmanItemUpdatorBuilder.php +0 −2 Go to diff View file
M plugins/docman/include/REST/v1/DocmanLinksResource.php +4 −14 Go to diff View file
M plugins/docman/include/REST/v1/DocmanWikiResource.php +3 −6 Go to diff View file
M plugins/docman/include/REST/v1/EmbeddedFiles/DocmanEmbeddedFileUpdator.php +17 −16 Go to diff View file
M plugins/docman/include/REST/v1/Files/DocmanItemFileUpdator.php +14 −19 Go to diff View file
M plugins/docman/include/REST/v1/Links/DocmanLinkUpdator.php +10 −10 Go to diff View file
M plugins/docman/include/REST/v1/Wiki/DocmanWikiUpdator.php +17 −23 Go to diff View file
A plugins/docman/phpunit/REST/v1/EmbeddedFiles/DocmanEmbeddedFileUpdatorTest.php +175 −0 Go to diff View file
M plugins/docman/phpunit/REST/v1/Files/DocmanItemFileUpdatorTest.php +44 −19 Go to diff View file
A plugins/docman/phpunit/REST/v1/Links/DocmanLinkUpdatorTest.php +230 −0 Go to diff View file
A plugins/docman/phpunit/REST/v1/Wiki/DocmanWikiUpdatorTest.php +167 −0 Go to diff View file
M plugins/docman/tests/rest/Docman/DocmanItemsTestFilesEmbeddedTest.php +2 −2 Go to diff View file
M plugins/docman/tests/rest/Docman/DocmanItemsTestFilesTest.php +44 −41 Go to diff View file
M plugins/docman/tests/rest/Docman/DocmanItemsTestLinksTest.php +2 −2 Go to diff View file
M plugins/docman/tests/rest/Docman/DocmanItemsTestWikiTest.php +2 −2 Go to diff View file
M plugins/docman/tests/rest/helper/DocmanFileDataBuild.php +21 −10 Go to diff View file