mirror of
https://we.phorge.it/source/phorge.git
synced 2024-12-23 14:00:56 +01:00
21 lines
505 B
PHP
21 lines
505 B
PHP
|
<?php
|
||
|
|
||
|
$table = new DifferentialRevision();
|
||
|
$conn = $table->establishConnection('w');
|
||
|
|
||
|
$drafts = $table->loadAllWhere(
|
||
|
'status = %s',
|
||
|
DifferentialRevisionStatus::DRAFT);
|
||
|
foreach ($drafts as $draft) {
|
||
|
$properties = $draft->getProperties();
|
||
|
|
||
|
$properties[DifferentialRevision::PROPERTY_SHOULD_BROADCAST] = false;
|
||
|
|
||
|
queryfx(
|
||
|
$conn,
|
||
|
'UPDATE %T SET properties = %s WHERE id = %d',
|
||
|
id(new DifferentialRevision())->getTableName(),
|
||
|
phutil_json_encode($properties),
|
||
|
$draft->getID());
|
||
|
}
|