[rt-users] $self->SUPER::SetPassword() returns "0, Nonexistant field?" in User_Overlay.pm

Jesse Vincent jesse at bestpractical.com
Sun Sep 7 13:47:25 EDT 2008


On Sep 5, 2008, at 9:46 PM, Ole Craig wrote:

> (rt 3.8.1rc5)
>
> I've got some custom functionality in a User_Local.pm file, trying to
> call the SetPassword method from lib/RT/User_Overlay.pm. This method
> always returns ("0", "Nonexistant field?") when trying to get results
> from a call to the method it's overriding; the call is around line 893
> in User_Overlay.pm, in this block:
>
> my $new = !$self->HasPassword;
> $password = $self->_GeneratePassword($password);
> my ( $val, $msg ) = $self->SUPER::SetPassword($password);
> if ($val) {
>    return ( 1, $self->loc("Password set") ) if $new;
>    return ( 1, $self->loc("Password changed") );
> }
> else {
>    return ( $val, $msg );
> }
>

Is your actual method called SetPassword? If so, then you need to be  
calling _Set or __Set rather than SetPassword. If your method isn't  
SetPassword, you just want to call SetPassword on the local object.


> @ISA at this point only contains RT::Record, which doesn't have an
> explicit SetPassword method but is (probably not coincidentally) the
> only place in the RT tree where I can find the string "Nonexistant
> field?". Obviously Set* is defined in here, but this level of
> indirection is beyond my extremely limited ooperl-fu. Can someone tell
> me what field is nonexistant[sic] here, and why, and what I can do to
> fix/workaround?
>
> 	Thanks,
> 		Ole
>
>
> -
> /Ole Craig
> Security Engineer
> Team lead, customer support
>
> ocraig at stillsecure.com
> 303-381-3802 main support line
> 303-381-3824 my voicemail
> 303-381-3880 fax
>
> www.stillsecure.com
>
> _______________________________________________
> http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users
>
> Community help: http://wiki.bestpractical.com
> Commercial support: sales at bestpractical.com
>
>
> Discover RT's hidden secrets with RT Essentials from O'Reilly Media.
> Buy a copy at http://rtbook.bestpractical.com
>




More information about the rt-users mailing list