Update Keywords for WebGUI::Definition and exceptions.

This commit is contained in:
Colin Kuskie 2010-01-28 13:12:44 -08:00
parent e873f5e653
commit f92f0d706a

View file

@ -128,7 +128,10 @@ sub findKeywords {
$parentAsset = $options->{asset};
}
if ($options->{assetId}) {
$parentAsset = WebGUI::Asset->new($self->session, $options->{assetId});
$parentAsset = eval { WebGUI::Asset->newById($self->session, $options->{assetId}); };
if (Exception::Class->caught()) {
$self->session->log->error("Keywords: error instanciating parentAsset by assetId ". $options->{assetId}.": $@");
}
}
if ($parentAsset) {
$sql .= ' INNER JOIN asset USING (assetId)';