Subject: | Redundant condition in Geo::Calc's code |
While reading Geo::Calc's code, I noticed a piece of code that is completely redundant. I've attached a patch that removes this piece of code.
Subject: | Remove-confusing-code.patch |
diff --git a/lib/Geo/Calc.pm b/lib/Geo/Calc.pm
index db17eff..fa58026 100644
--- a/lib/Geo/Calc.pm
+++ b/lib/Geo/Calc.pm
@@ -377,11 +377,7 @@ of the boundry box, given the widht and height
=cut
method boundry_box( Num $width!, Maybe[Num] $height?, Int $precision? = -6 ) returns (HashRef[Num]) {
- if( !defined( $precision ) ) {
- $width *= 2;
- $height = $width;
- $precision = -6;
- } elsif( !defined( $height ) ) {
+ if ( !defined( $height ) ) {
$width *= 2;
$height = $width;
}
--