remove WebGUI::Utility::isIn

This commit is contained in:
Graham Knop 2010-09-07 12:33:15 -05:00
parent 0e754a51e4
commit 6aa26c2e44
61 changed files with 126 additions and 148 deletions

View file

@ -43,7 +43,7 @@ print "\nLooking for orphans...\n" unless ($quiet);
my $orphansFound = 0;
my $rs = $session->db->read("select assetId from asset order by lineage");
while (my ($id) = $rs->array) {
unless (isIn($id, @found)) {
unless ($id ~~ @found) {
print "\tFound an orphan with an assetId of $id. Moving it to the import node.\n";
$session->db->write("update asset set parentId='PBasset000000000000002' where assetId=?",[$id]);
getDescendants($id);
@ -80,7 +80,7 @@ print "\nDon't forget to clear your cache.\n" unless ($quiet);
sub getDescendants {
my $parentId = shift;
my $depth = shift || 0;
if (isIn($parentId, @found)) {
if ($parentId ~~ @found) {
print "\nFound circular relationships involving $parentId. This requires manual intervention.\n" unless ($quiet);
exit;
}