Index: trunk/PS-IPP-Config/lib/PS/IPP/Config.pm
===================================================================
--- trunk/PS-IPP-Config/lib/PS/IPP/Config.pm	(revision 24209)
+++ trunk/PS-IPP-Config/lib/PS/IPP/Config.pm	(revision 24406)
@@ -370,4 +370,6 @@
     my $proj_id = $ref->{proj_id};
     $stmt->finish();
+    ( carp "proj_id for $dbname not found in $admindb" and return undef ) unless $proj_id;
+
 
     my $source_id = ($proj_id << 3) | $table;
@@ -1268,18 +1270,18 @@
     # check if file actually exists
     if ($self->file_exists( $outname )) {
-	# double check that the file is not zero-length (eg: dvoImageExtract crashed)
+        # double check that the file is not zero-length (eg: dvoImageExtract crashed)
         $outnameResolved = $self->file_resolve( $outname, 1 ) or return undef; # Resolved filename, for Nebulous
-	my @stats = stat($outnameResolved);
-	if ($stats[7]) {
-	    return 1;
-	}
+        my @stats = stat($outnameResolved);
+        if ($stats[7]) {
+            return 1;
+        }
     }
 
     unless (defined $outnameResolved) {
-	$outnameResolved = $self->file_create( $outname ) or return undef; # Resolved filename, for Nebulous
+        $outnameResolved = $self->file_create( $outname ) or return undef; # Resolved filename, for Nebulous
     }
     my $command = "$dvoImageExtract -D CATDIR $tess_dir $skycell_id -o $outnameResolved";
     my ( $success, $error_code, $full_buf, $stdout_buf, $stderr_buf ) =
-	run(command => $command, verbose => $verbose);
+        run(command => $command, verbose => $verbose);
     ( carp "Unable to perform dvoImageExtract for $tess_id $skycell_id\n" and return undef ) unless ($success and $self->file_exists( $outname ));
 
