josh803316 has asked for the wisdom of the Perl Monks concerning the following question:
but for some reason inside my base class Object using method find the caller is not seen as the $class (User) it is seen as the Package (MyModule) that contains the eval. How would I change this to test for the correct Caller with caller->isa since the caller is not seen as $class.package MyModule; eval { # $class is User (which uses Object as base) # example $db_response = User->find($query) $db_response = $class->$method($query); };
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: caller package and eval
by ikegami (Patriarch) on Sep 02, 2009 at 01:48 UTC | |
by josh803316 (Beadle) on Sep 02, 2009 at 01:55 UTC | |
by ikegami (Patriarch) on Sep 02, 2009 at 02:07 UTC | |
by josh803316 (Beadle) on Sep 02, 2009 at 06:10 UTC |