#!/usr/bin/perl -w
use strict;

use lib 'lib';

use MT;
my $mt = MT->new or die MT->errstr;

my($class, $id) = @ARGV;
die "usage: $0 <object-class> <object-id>"
    unless $class && $id;
eval "use $class;";
die "Error loading '$class': $@" if $@;

my $obj = $class->load($id) or
    die "Load of object with ID $id failed: " . $class->errstr;
$obj->remove;
