Changeset 298


Ignore:
Timestamp:
Nov 2, 2006, 9:56:58 PM (13 years ago)
Author:
Dominic Hargreaves
Message:

Remove crud

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/npemap.org.uk/scripts/content/update_stats.pl

    r230 r298  
    88
    99use FindBin;
    10 use DBI;
    1110
    1211# Find our private perl libraries
     
    1514use NPEMap;
    1615
    17 sub print_err;
    18 sub setup_dbh;
    1916
    20 my $dbh;
    21 
    22     # In case the database went away, make sure we have a connection
    23     unless ($dbh = setup_dbh()) {
    24         print_internal_err('Error setting up database connection');
    25     }
     17my $dbh = setup_dbh();
    2618
    2719build_home_stats($dbh);
    2820
    2921$dbh->disconnect;
    30 
    31 # Helper routines
    32 sub print_err {
    33     my $err = shift;
    34     print header("text/plain", "400 $err");
    35     print "Error: $err\n";
    36 }
    37 
    38 sub print_internal_err {
    39     my $err = shift;
    40     print header("text/plain", "500 $err");
    41     print "Error: $err\n";
    42 }
Note: See TracChangeset for help on using the changeset viewer.