1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-11-30 02:32:42 +01:00
phorge-phorge/resources/sql/autopatches/20141218.maniphestcctxn.php

22 lines
540 B
PHP
Raw Normal View History

<?php
$table = new ManiphestTransaction();
$conn_w = $table->establishConnection('w');
echo pht(
"Converting Maniphest CC transactions to modern ".
"subscriber transactions...\n");
foreach (new LiskMigrationIterator($table) as $txn) {
// ManiphestTransaction::TYPE_CCS
if ($txn->getTransactionType() == 'ccs') {
queryfx(
$conn_w,
'UPDATE %T SET transactionType = %s WHERE id = %d',
$table->getTableName(),
PhabricatorTransactions::TYPE_SUBSCRIBERS,
$txn->getID());
}
}
echo pht('Done.')."\n";