# -*- perl -*-
use strict; use warnings FATAL => qw/FATAL all NONFATAL misc/;

sub {
  my ($this, $con) = @_;
  my MY $yatt = $this->YATT;

  unless ($con->param('!cancel')) {
    my $fnum = $con->param_type(fnum => integer => "fnum should be integer!");

    # XXX: This can loose old content!
    unlink "$yatt->{cf_datadir}/.ht_$fnum"
      or die "Can't delete $fnum: $!";
  }

  $con->redirect('./');
};