Skip to content

Commit

Permalink
Only use the API message when we actually didn't get any raw content
Browse files Browse the repository at this point in the history
Switches to checking the API response data rather than the stash after
processing through HTML::Restrict.  If HTML::Restrict fails, the lack of
pod may not be related to any API message.
  • Loading branch information
tsibley committed Mar 28, 2014
1 parent d05a564 commit 21b3bfc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/MetaCPAN/Web/Controller/Pod.pm
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ sub view : Private {
canonical => $canonical,
}
);
unless ( $c->stash->{pod} ) {
unless ( $reqs->{pod}->{raw} ) {
$c->stash( pod_error => $reqs->{pod}->{message}, );
}
}
Expand Down

0 comments on commit 21b3bfc

Please sign in to comment.