Bug 26555 adds a way for Koha::Object-derived classes to carry errors messages between method calls. On bug 26651 there's a proposal for a Koha::Object->reset_messages method that *could* be used to clean that messages list, if required. Another option could be to have Koha::Object::Message carry some flag (seen?) that tells if the message has already been looked at. So if ->messages is called twice, the second one returns no results as all messages have been marked as seen: =head3 messages $object->methods ->that ->each ->adds ->messages; @messages = $object->messages; # all accumulated messages @messages = $object->messages; # @messages is empty $object->boo; @messages = $object->messages; # @messages contains messages added by ->boo The implementation could look like: =cut sub messages { my ($self) = @_; my @messages = map { $_->mark_as_seen } @{ grep { $_->unseen } @{ $self->messages } }; return \@messages; } package Koha::Object::Message; sub mark_as_seen { my ($self) = @_; $self->{seen} = 1; return $self; } A method for retrieving all messages in the object lifetime could be added. I put this here for discussing it, and just in case someone is looking for something like this and finds this bug, adding their two cents here with their use cases.