diff --git a/src/applications/differential/controller/DifferentialInlineCommentEditController.php b/src/applications/differential/controller/DifferentialInlineCommentEditController.php index c09caa9374..619990b731 100644 --- a/src/applications/differential/controller/DifferentialInlineCommentEditController.php +++ b/src/applications/differential/controller/DifferentialInlineCommentEditController.php @@ -60,8 +60,9 @@ final class DifferentialInlineCommentEditController return false; } - // Saved comments may not be edited. - if ($inline->getCommentID()) { + // Saved comments may not be edited, for now, although the schema now + // supports it. + if (!$inline->isDraft()) { return false; } diff --git a/src/applications/differential/query/DifferentialInlineCommentQuery.php b/src/applications/differential/query/DifferentialInlineCommentQuery.php index 8eb59760c1..cd338b74c1 100644 --- a/src/applications/differential/query/DifferentialInlineCommentQuery.php +++ b/src/applications/differential/query/DifferentialInlineCommentQuery.php @@ -45,11 +45,6 @@ final class DifferentialInlineCommentQuery return $this; } - public function withCommentIDs(array $comment_ids) { - $this->commentIDs = $comment_ids; - return $this; - } - public function execute() { $table = new DifferentialTransactionComment(); $conn_r = $table->establishConnection('r'); @@ -155,13 +150,6 @@ final class DifferentialInlineCommentQuery $this->draftsByAuthors); } - if ($this->commentIDs) { - $where[] = qsprintf( - $conn_r, - 'legacyCommentID IN (%Ld)', - $this->commentIDs); - } - return $this->formatWhereClause($where); } diff --git a/src/applications/differential/storage/DifferentialInlineComment.php b/src/applications/differential/storage/DifferentialInlineComment.php index 4e7dcf47a7..928104d9d6 100644 --- a/src/applications/differential/storage/DifferentialInlineComment.php +++ b/src/applications/differential/storage/DifferentialInlineComment.php @@ -167,7 +167,6 @@ final class DifferentialInlineComment // the future transaction. public function setCommentID($id) { - $this->proxy->setLegacyCommentID($id); $this->proxy->setTransactionPHID( PhabricatorPHID::generateNewPHID( PhabricatorApplicationTransactionPHIDTypeTransaction::TYPECONST, @@ -175,11 +174,6 @@ final class DifferentialInlineComment return $this; } - public function getCommentID() { - return $this->proxy->getLegacyCommentID(); - } - - /* -( PhabricatorMarkupInterface Implementation )-------------------------- */ @@ -202,7 +196,7 @@ final class DifferentialInlineComment public function shouldUseMarkupCache($field) { // Only cache submitted comments. - return ($this->getID() && $this->getCommentID()); + return ($this->getID() && !$this->isDraft()); } }