From b7f7b8aff0feaaabcce338fe23222e1c63e3a3a4 Mon Sep 17 00:00:00 2001 From: Bob Trahan Date: Fri, 25 Jan 2013 13:04:40 -0800 Subject: [PATCH] Conpherence - hide file transactions Summary: added support for when showHide is true AND set showHide to true for Files. Test Plan: loaded a conpherence and saw no more "updated files" transacations Reviewers: chad, epriestley Reviewed By: chad CC: aran, Korvin Maniphest Tasks: T2399, T2411 Differential Revision: https://secure.phabricator.com/D4649 --- .../conpherence/controller/ConpherenceViewController.php | 3 +++ .../conpherence/storage/ConpherenceTransaction.php | 3 ++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/src/applications/conpherence/controller/ConpherenceViewController.php b/src/applications/conpherence/controller/ConpherenceViewController.php index 925843c45c..173b3c5c47 100644 --- a/src/applications/conpherence/controller/ConpherenceViewController.php +++ b/src/applications/conpherence/controller/ConpherenceViewController.php @@ -112,6 +112,9 @@ final class ConpherenceViewController extends $transactions = $conpherence->getTransactions(); foreach ($transactions as $transaction) { + if ($transaction->shouldHide()) { + continue; + } $rendered_transactions[] = id(new ConpherenceTransactionView()) ->setUser($user) ->setConpherenceTransaction($transaction) diff --git a/src/applications/conpherence/storage/ConpherenceTransaction.php b/src/applications/conpherence/storage/ConpherenceTransaction.php index c75ee7cd1f..9b242275c6 100644 --- a/src/applications/conpherence/storage/ConpherenceTransaction.php +++ b/src/applications/conpherence/storage/ConpherenceTransaction.php @@ -29,8 +29,9 @@ final class ConpherenceTransaction extends PhabricatorApplicationTransaction { return ($old === null); case ConpherenceTransactionType::TYPE_TITLE: case ConpherenceTransactionType::TYPE_PICTURE: - case ConpherenceTransactionType::TYPE_FILES: return false; + case ConpherenceTransactionType::TYPE_FILES: + return true; } return parent::shouldHide();