X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=maintenance%2FcleanupUploadStash.php;h=95bbe3d3ffd8fc4a0f6c40af6fbcc9b9dc7bd7a2;hb=6f567677852d0cd047d1f2485f6c364879775acd;hp=3c768d87a3866c26c7fdb6f9399eaf4e5f2efeaa;hpb=a78975403fefa62cbd0c9d57acc94066c4901b7b;p=lhc%2Fweb%2Fwiklou.git diff --git a/maintenance/cleanupUploadStash.php b/maintenance/cleanupUploadStash.php index 3c768d87a3..95bbe3d3ff 100644 --- a/maintenance/cleanupUploadStash.php +++ b/maintenance/cleanupUploadStash.php @@ -47,7 +47,7 @@ class UploadStashCleanup extends Maintenance { $repo = RepoGroup::singleton()->getLocalRepo(); $tempRepo = $repo->getTempRepo(); - $dbr = $repo->getSlaveDB(); + $dbr = $repo->getReplicaDB(); // how far back should this look for files to delete? $cutoff = time() - $wgUploadStashMaxAge; @@ -74,7 +74,7 @@ class UploadStashCleanup extends Maintenance { // this could be done some other, more direct/efficient way, but using // UploadStash's own methods means it's less likely to fall accidentally // out-of-date someday - $stash = new UploadStash( $repo, new User() ); + $stash = new UploadStash( $repo ); $i = 0; foreach ( $keys as $key ) {