From e07570cad5306d86da375d239f84bbae91015595 Mon Sep 17 00:00:00 2001 From: Mike Taylor Date: Wed, 27 Sep 2006 12:40:44 +0000 Subject: [PATCH] callback() now removes a callback if called with an undefined argument. --- lib/ZOOM/Pod.pm | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lib/ZOOM/Pod.pm b/lib/ZOOM/Pod.pm index df8e2ad..280f099 100644 --- a/lib/ZOOM/Pod.pm +++ b/lib/ZOOM/Pod.pm @@ -1,4 +1,4 @@ -# $Id: Pod.pm,v 1.19 2006-09-26 08:52:21 mike Exp $ +# $Id: Pod.pm,v 1.20 2006-09-27 12:40:44 mike Exp $ package ZOOM::Pod; @@ -205,8 +205,7 @@ sub callback { my($event, $sub) = @_; my $old = $this->{callback}->{$event}; - $this->{callback}->{$event} = $sub - if defined $sub; + $this->{callback}->{$event} = $sub; return $old; } -- 1.7.10.4