Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F15334262
D21460.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
D21460.diff
View Options
diff --git a/src/applications/repository/engine/PhabricatorRepositoryRefEngine.php b/src/applications/repository/engine/PhabricatorRepositoryRefEngine.php
--- a/src/applications/repository/engine/PhabricatorRepositoryRefEngine.php
+++ b/src/applications/repository/engine/PhabricatorRepositoryRefEngine.php
@@ -553,6 +553,7 @@
}
$closeable_flag = PhabricatorRepositoryCommit::IMPORTED_CLOSEABLE;
+ $published_flag = PhabricatorRepositoryCommit::IMPORTED_PUBLISH;
$all_commits = ipull($all_commits, null, 'commitIdentifier');
foreach ($identifiers as $identifier) {
@@ -566,12 +567,21 @@
$identifier));
}
- if (!($row['importStatus'] & $closeable_flag)) {
+ $import_status = $row['importStatus'];
+ if (!($import_status & $closeable_flag)) {
+ // Set the "closeable" flag.
+ $import_status = ($import_status | $closeable_flag);
+
+ // See T13580. Clear the "published" flag, so publishing executes
+ // again. We may have previously performed a no-op "publish" on the
+ // commit to make sure it has all bits in the "IMPORTED_ALL" bitmask.
+ $import_status = ($import_status & ~$published_flag);
+
queryfx(
$conn,
- 'UPDATE %T SET importStatus = (importStatus | %d) WHERE id = %d',
+ 'UPDATE %T SET importStatus = %d WHERE id = %d',
$commit_table->getTableName(),
- $closeable_flag,
+ $import_status,
$row['id']);
$data = array(
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sun, Mar 9, 7:55 AM (12 h, 1 m ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
7387502
Default Alt Text
D21460.diff (1 KB)
Attached To
Mode
D21460: When a commit is marked "closeable", clear the "published" flag
Attached
Detach File
Event Timeline
Log In to Comment