mirror of
https://we.phorge.it/source/phorge.git
synced 2024-11-27 09:12:41 +01:00
19 lines
373 B
PHP
19 lines
373 B
PHP
|
<?php
|
||
|
|
||
|
echo "Giving image macros PHIDs";
|
||
|
foreach (new LiskMigrationIterator(new PhabricatorFileImageMacro()) as $macro) {
|
||
|
if ($macro->getPHID()) {
|
||
|
continue;
|
||
|
}
|
||
|
|
||
|
echo ".";
|
||
|
|
||
|
queryfx(
|
||
|
$macro->establishConnection('r'),
|
||
|
'UPDATE %T SET phid = %s WHERE id = %d',
|
||
|
$macro->getTableName(),
|
||
|
$macro->generatePHID(),
|
||
|
$macro->getID());
|
||
|
}
|
||
|
echo "\nDone.\n";
|