From cceeacee1d59a40b903df1c87f0aaf2ff9565093 Mon Sep 17 00:00:00 2001 From: Jesse Luehrs Date: Sat, 31 Oct 2009 16:05:11 -0500 Subject: avoid another undef warning --- lib/IM/Engine/Plugin/Commands/Trait/Method/Formatted.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/IM/Engine/Plugin/Commands/Trait/Method/Formatted.pm b/lib/IM/Engine/Plugin/Commands/Trait/Method/Formatted.pm index 82dcd04..adef334 100644 --- a/lib/IM/Engine/Plugin/Commands/Trait/Method/Formatted.pm +++ b/lib/IM/Engine/Plugin/Commands/Trait/Method/Formatted.pm @@ -14,7 +14,7 @@ has formatter => ( sub _munge_formatter { my $self = shift; my ($format) = @_; - return $format if reftype($format) eq 'CODE'; + return $format if defined(reftype($format)) && reftype($format) eq 'CODE'; return $self->associated_metaclass->formatter_for($format); } -- cgit v1.2.3-54-g00ecf