[Rt-commit] rt branch, 4.2/bookmarks-in-lib, updated. rt-4.0.0rc6-161-g2205ca5
Shawn Moore
sartak at bestpractical.com
Tue Mar 8 14:27:31 EST 2011
The branch, 4.2/bookmarks-in-lib has been updated
via 2205ca5ae8213b30b1ff422f264f6b741f89eb45 (commit)
from b5f0c48a321bfb48d50f1768bf1494638f15f088 (commit)
Summary of changes:
lib/RT/Ticket.pm | 12 ++++--------
1 files changed, 4 insertions(+), 8 deletions(-)
- Log -----------------------------------------------------------------
commit 2205ca5ae8213b30b1ff422f264f6b741f89eb45
Author: Shawn M Moore <sartak at bestpractical.com>
Date: Tue Mar 8 14:27:25 2011 -0500
Just always push on the Merged list
diff --git a/lib/RT/Ticket.pm b/lib/RT/Ticket.pm
index 715b1c8..b1689ff 100644
--- a/lib/RT/Ticket.pm
+++ b/lib/RT/Ticket.pm
@@ -3690,10 +3690,8 @@ sub IsBookmarked {
my $self = shift;
my $id = $self->id;
- my @ids = $id;
- if ($id != $self->EffectiveId) {
- push @ids, $self->Merged;
- }
+ # maintain bookmarks across merges
+ my @ids = ($id, $self->Merged);
my $bookmarks = $self->CurrentUser->UserObj->FirstAttribute('Bookmarks');
$bookmarks = $bookmarks ? $bookmarks->Content : {};
@@ -3712,10 +3710,8 @@ sub ToggleBookmark {
my $self = shift;
my $id = $self->id;
- my @ids = $id;
- if ($id != $self->EffectiveId) {
- push @ids, $self->Merged;
- }
+ # maintain bookmarks across merges
+ my @ids = ($id, $self->Merged);
my $bookmarks = $self->CurrentUser->UserObj->FirstAttribute('Bookmarks');
$bookmarks = $bookmarks ? $bookmarks->Content : {};
-----------------------------------------------------------------------
More information about the Rt-commit
mailing list