Change calls to new to newById across Asset/

This commit is contained in:
Colin Kuskie 2010-03-03 16:27:45 -08:00
parent da574279d9
commit 814c2af249
55 changed files with 98 additions and 98 deletions

View file

@ -506,7 +506,7 @@ sub run {
# Instantiate the asset to check it is a Survey instance, and to grab its assetId
if ( $session->id->valid($asset_spec) ) {
$asset = WebGUI::Asset->new( $session, $asset_spec );
$asset = WebGUI::Asset->newById( $session, $asset_spec );
}
if ( !$asset ) {
$asset = WebGUI::Asset->newByUrl( $session, $asset_spec );

View file

@ -127,7 +127,7 @@ sub run {
}
my $assetId = $self->get('assetId');
my $survey = WebGUI::Asset::Wobject::Survey->new($session, $assetId);
my $survey = WebGUI::Asset::Wobject::Survey->newById($session, $assetId);
if (!$survey || !$survey->isa('WebGUI::Asset::Wobject::Survey') ) {
return { tap => "Bail Out! Unable to instantiate Survey using assetId: $assetId" };
}