Index: /branches/haf_add201112/ippScripts/scripts/addstar_run.pl
===================================================================
--- /branches/haf_add201112/ippScripts/scripts/addstar_run.pl	(revision 33022)
+++ /branches/haf_add201112/ippScripts/scripts/addstar_run.pl	(revision 33023)
@@ -115,5 +115,6 @@
 # it was PSASTRO.OUTPUT
 
-my $fpaObjects;
+my $fpaObjects = $ipprc->filename("PSASTRO.OUTPUT", $stageroot) or &my_die("Missing entry from camera config", $add_id, $PS_EXIT_CONFIG_ERROR);
+
 if ($stage =~ /cam/) {
     # if it is cam stage we need to be careful when grabbing the filename. 
@@ -150,15 +151,10 @@
 	#is this cam_id magicked or not?
 	if ($magicked) {
-	    $fpaObjects = $ipprc->destreak_filename("PSASTRO.OUTPUT",     $stageroot) or &my_die("Missing entry from camera config", $add_id, $PS_EXIT_CONFIG_ERROR);
+	    $fpaObjects = $ipprc->destreaked_filename("$fpaObjects") or &my_die("Missing entry from camera config", $add_id, $PS_EXIT_CONFIG_ERROR);
 	    print "cam_id is magicked, using $fpaObjects for the cam smf\n";
 	} else {
-	    
-	    $fpaObjects = $ipprc->filename("PSASTRO.OUTPUT",     $stageroot) or &my_die("Missing entry from camera config", $add_id, $PS_EXIT_CONFIG_ERROR);
 	    print "cam_id is NOT magicked, using $fpaObjects for the cam smf\n";
 	}
     }
-} else {
-    # for non cam stages, grabe the file name like this:
-    $fpaObjects = $ipprc->filename("PSASTRO.OUTPUT",     $stageroot) or &my_die("Missing entry from camera config", $add_id, $PS_EXIT_CONFIG_ERROR);
 }
 if (($stage =~/staticsky/) || ($stage =~/stack/)) {
Index: /branches/haf_add201112/ippScripts/scripts/minidvodb_premerge.pl
===================================================================
--- /branches/haf_add201112/ippScripts/scripts/minidvodb_premerge.pl	(revision 33022)
+++ /branches/haf_add201112/ippScripts/scripts/minidvodb_premerge.pl	(revision 33023)
@@ -79,8 +79,8 @@
 
 unless ($no_op) {
-    {
+    
 	#this is chopped into several parts: addstar, relphot
 	#addstar
-        {
+	{
             my $command  = "$addstar -resort";
             $command .= " -D CAMERA $camera";
@@ -110,5 +110,5 @@
 	    print "$command\n";
             my $mjd_relphot_start = DateTime->now->mjd;   # MJD of starting script
-
+	    
             my ( $success, $error_code, $full_buf, $stdout_buf, $stderr_buf ) =
                 run(command => $command, verbose => $verbose);
@@ -122,5 +122,5 @@
 
 	{
-
+	    
 	    $dtime_script = 86400.0*(DateTime->now->mjd - $mjd_start);
             my $command = "addtool -minidvodb_id $minidvodb_id";
@@ -139,7 +139,7 @@
             }
         }
-    } else {
-        &my_die("dvodb: minidvodb_id = $minidvodb_id not found", $minidvodb_id, $PS_EXIT_UNKNOWN_ERROR);
-    }
+#} else {
+#    &my_die("dvodb: minidvodb_id = $minidvodb_id not found", $minidvodb_id, $PS_EXIT_UNKNOWN_ERROR);
+#}
 } else {
     print "skipping processing for minidvodb_id = $minidvodb_id\n";
Index: /branches/haf_add201112/ippTools/src/addtool.c
===================================================================
--- /branches/haf_add201112/ippTools/src/addtool.c	(revision 33022)
+++ /branches/haf_add201112/ippTools/src/addtool.c	(revision 33023)
@@ -292,7 +292,8 @@
     } else {
       //This picks only the unmagicked/uncensored ones
-      if (strcmp(stage,"cam") == 0) {
-        psStringAppend(&query, " AND (camRun.magicked = 0)");
-      }
+      //if (strcmp(stage,"cam") == 0) {
+	//we can now properly handle the magicked case in ippScripts, so we queue camRuns in any magic state now if -uncensored.
+        //psStringAppend(&query, " AND (camRun.magicked = 0)");
+	//}
       if (strcmp(stage,"stack") == 0) {
 	psStringAppend(&query, " AND (stackRun.magicked = 0)");
