Explicit return of undef in the fall through case. Test for notFound now look for undef. Added POD.

This commit is contained in:
Colin Kuskie 2010-07-29 12:14:18 -07:00
parent 7e96b15141
commit c987747409
2 changed files with 17 additions and 5 deletions

View file

@ -563,11 +563,16 @@ sub definition {
=head2 dispatch ( $fragment )
Based on the URL and query parameters in the current request, call internal methods
like www_view, www_edit, etc.
like www_view, www_edit, etc. If no query parameter is present, then it returns the output
from the view method.
When this method returns undef, it means that the requested URL does not match this Asset's
URL.
=head3 $fragment
A URL.
A URL. If this URL is missing, then output from the view method is returned.
If the fragment does not match this Asset's URL, then it returns undef.
=cut
@ -582,6 +587,7 @@ sub dispatch {
if (! $fragment ) {
return $self->www_view;
}
return undef;
}