@recaptime-dev's working patches + fork for Phorge, a community fork of Phabricator. (Upstream dev and stable branches are at upstream/main and upstream/stable respectively.) hq.recaptime.dev/wiki/Phorge
phorge phabricator
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Permanently destroy Almanac properties with the destruction engine

Summary: As suggested in D14461.

Test Plan: Used `./bin/remove destroy` on an Almanac service with properties attached, saw entries removed from the `phabricator_almanac.almanac_property` table.

Reviewers: epriestley, #blessed_reviewers

Reviewed By: epriestley, #blessed_reviewers

Subscribers: Korvin

Differential Revision: https://secure.phabricator.com/D14490

authored by

Joshua Spence and committed by
joshuaspence
1a84a2fe 67b6c532

+15
+15
src/applications/system/engine/PhabricatorDestructionEngine.php
··· 92 92 $token->delete(); 93 93 } 94 94 } 95 + 96 + if ($object instanceof AlmanacPropertyInterface) { 97 + $this->destroyAlmanacProperties($object_phid); 98 + } 95 99 } 96 100 97 101 private function destroyEdges($src_phid) { ··· 144 148 queryfx( 145 149 $conn_w, 146 150 'DELETE FROM %T WHERE primaryObjectPHID = %s', 151 + $table->getTableName(), 152 + $object_phid); 153 + } 154 + 155 + private function destroyAlmanacProperties($object_phid) { 156 + $table = new AlmanacProperty(); 157 + $conn_w = $table->establishConnection('w'); 158 + 159 + queryfx( 160 + $conn_w, 161 + 'DELETE FROM %T WHERE objectPHID = %s', 147 162 $table->getTableName(), 148 163 $object_phid); 149 164 }