Skip to content
Snippets Groups Projects
Commit 8350b7fb authored by Andreas Kusalananda Kähäri's avatar Andreas Kusalananda Kähäri
Browse files

In expand(): Correct broken merge, from Dan S.

parent c8a39c28
No related branches found
No related tags found
No related merge requests found
...@@ -1000,12 +1000,19 @@ sub expand { ...@@ -1000,12 +1000,19 @@ sub expand {
return undef; return undef;
} }
my $new_start;
my $new_end;
my $sshift = $five_prime_shift; my $sshift = $five_prime_shift;
my $eshift = $three_prime_shift; my $eshift = $three_prime_shift;
if ( $self->{'strand'} != 1 ) {
$eshift = $five_prime_shift;
$sshift = $three_prime_shift;
}
my $new_start = $self->{'start'} - $sshift;
my $new_end = $self->{'end'} + $eshift;
if ( $self->is_circular() ) { if ( $self->is_circular() ) {
if ( $new_start <= 0 ) { if ( $new_start <= 0 ) {
$new_start = $self->seq_region_length() + $new_start; $new_start = $self->seq_region_length() + $new_start;
} }
...@@ -1020,15 +1027,8 @@ sub expand { ...@@ -1020,15 +1027,8 @@ sub expand {
$new_end -= $self->seq_region_length(); $new_end -= $self->seq_region_length();
} }
} else {
if ( $self->{'strand'} != 1 ) {
$eshift = $five_prime_shift;
$sshift = $three_prime_shift;
}
$new_start = $self->{'start'} - $sshift; } else {
$new_end = $self->{'end'} + $eshift;
if ( $new_start > $new_end ) { if ( $new_start > $new_end ) {
if ($force_expand) { if ($force_expand) {
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment