diff --git a/misc-scripts/xref_mapping/XrefParser/WormPepParser.pm b/misc-scripts/xref_mapping/XrefParser/WormPepParser.pm
index 8086a7ae9cf09a1d8fa709ae29d3ad78ed5ad398..522c3544ed0b7a364b856408e606c3d67aeb579d 100644
--- a/misc-scripts/xref_mapping/XrefParser/WormPepParser.pm
+++ b/misc-scripts/xref_mapping/XrefParser/WormPepParser.pm
@@ -43,7 +43,6 @@ sub run {
     my ($transcript, $wb, $display)  = (split(/\t/,substr($_,1)))[0,1,2];
 
     # reuse or create xref
-    my $xref_id;
     $xref_sth->execute($wb);
     my $xref_id = ($xref_sth->fetchrow_array())[0];
     if (!$xref_id) {
@@ -55,7 +54,6 @@ sub run {
     $d_count++;
 
     if(defined($display) and length($display) > 0 ){
-      my $xref_id2;
       $xref_sth2->execute($display);
       my $xref_id2 = ($xref_sth2->fetchrow_array())[0];
       if (!$xref_id2) {