[Rt-commit] r10174 - rt/branches/3.999-DANGEROUS/lib/RT

sunnavy at bestpractical.com sunnavy at bestpractical.com
Fri Dec 28 02:30:40 EST 2007


Author: sunnavy
Date: Fri Dec 28 02:30:40 2007
New Revision: 10174

Modified:
   rt/branches/3.999-DANGEROUS/lib/RT/SavedSearch.pm

Log:
do_search to refresh current user's attributes when we delete a SavedSearch object

Modified: rt/branches/3.999-DANGEROUS/lib/RT/SavedSearch.pm
==============================================================================
--- rt/branches/3.999-DANGEROUS/lib/RT/SavedSearch.pm	(original)
+++ rt/branches/3.999-DANGEROUS/lib/RT/SavedSearch.pm	Fri Dec 28 02:30:40 2007
@@ -210,9 +210,11 @@
 
     my ($status, $msg) = $self->{'Attribute'}->delete;
     if ($status) {
-	return (1, _("Deleted search"));
+        # we need to do_search to refresh current user's attributes
+        $self->current_user->user_object->attributes->_do_search;
+	    return (1, _("Deleted search"));
     } else {
-	return (0, _("Delete failed: %1", $msg));
+	    return (0, _("Delete failed: %1", $msg));
     }
 }
 	


More information about the Rt-commit mailing list