From: Chris Prather Date: Tue, 23 Feb 2010 23:53:55 +0000 (-0500) Subject: kill passive voice in the trigger documentation X-Git-Tag: 0.99~12 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=c25ca3a6b3b2a39dfabe60a8b200a8ca8285b458;p=gitmo%2FMoose.git kill passive voice in the trigger documentation I was having difficulty understanding the parameters passed in to a trigger sub based on the documentation. I can only imagine that others were as well. I've re-written it to help make it hopefully clearer by reducing the usage of passive voice. --- diff --git a/lib/Moose.pm b/lib/Moose.pm index 565593e..76988d8 100644 --- a/lib/Moose.pm +++ b/lib/Moose.pm @@ -482,9 +482,9 @@ either C or C. =item I $code> The I option is a CODE reference which will be called after -the value of the attribute is set. The CODE ref will be passed the -instance itself and the updated value. If the attribute already had a -value, this will be passed as the third value to the trigger. +the value of the attribute is set. The CODE ref is passed the +instance itself, the updated value, and the original value if the +attribute was already set. You B have a trigger on a read-only attribute.