server icon indicating copy to clipboard operation
server copied to clipboard

Cleanup versions entities in during versions:clean command

Open artonge opened this issue 1 year ago • 5 comments

Forgoten place where we need to remove versions entities in the database.

Fix https://github.com/nextcloud/server/issues/39046

artonge avatar Feb 01 '24 15:02 artonge

/backport to stable28

artonge avatar Feb 01 '24 15:02 artonge

/backport to stable27

artonge avatar Feb 01 '24 15:02 artonge

/backport to stable26

artonge avatar Feb 01 '24 15:02 artonge

Well, looks like my commit is in master already… What happened to my pre push hook? https://github.com/nextcloud/server/commit/1ec9f3e5f9dd84723008137af73cf365beaf4d1b

artonge avatar Feb 01 '24 16:02 artonge

  1. OCA\Files_Versions\Tests\Command\CleanupTest::testDeleteVersions with data set #0 (true) ArgumentCountError: Too few arguments to function OCA\Files_Versions\Command\CleanUp::__construct(), 2 passed in /home/runner/work/server/server/apps/files_versions/tests/Command/CleanupTest.php on line 60 and exactly 3 expected

nickvergessen avatar Feb 01 '24 18:02 nickvergessen

For bonus phpoints™ you can split off the fileid chunk fetching into a generator to hopefully make it bit more readable than the mixing of queries

Indeed, improves separation of concern, thanks for the tip :)

artonge avatar Mar 05 '24 15:03 artonge

:sparkles: +1 phpoint™ for Louis :sparkles:

icewind1991 avatar Mar 05 '24 16:03 icewind1991