aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDuncan Parkes <duncan@fury.ukcod.org.uk>2011-02-18 20:27:28 +0000
committerDuncan Parkes <duncan@fury.ukcod.org.uk>2011-02-18 20:27:28 +0000
commita01bad958bc9889f23c77aa8c35223378c3150fc (patch)
tree3cc34a151f4ed4d09f1fb9342870c3210c52e9e4
parent99e985bd2181a34ac677438e9799456c4ee51008 (diff)
Remove some old commented code, and do what happened
before on an error from mapit (though it does give an Internal Server Error...)
-rwxr-xr-xweb/rss.cgi14
1 files changed, 3 insertions, 11 deletions
diff --git a/web/rss.cgi b/web/rss.cgi
index 2ee89115f..c4534e7f5 100755
--- a/web/rss.cgi
+++ b/web/rss.cgi
@@ -106,15 +106,14 @@ sub rss_local_problems {
} catch Error::Simple with {
$error = shift;
};
- unless ($error) {
+ if ($error) {
+ return '';
+ } else {
( $lat, $lon ) = map { Utils::truncate_coordinate($_) } ( $lat, $lon );
$qs = "?pc=$pc";
$title_params{'POSTCODE'} = encode_utf8($pc);
-
-# print $q->redirect(-location => "$base/rss/l/$lat,$lon$d_str$state_qs");
}
-# return '';
# pass through rather than redirecting.
} elsif ( $lat || $lon ) {
# pass through
@@ -139,7 +138,6 @@ sub rss_local_problems {
my $xsl = Cobrand::feed_xsl($cobrand);
-
if ($pc) {
$alert_type = 'postcode_local_problems';
} else {
@@ -154,11 +152,5 @@ sub rss_local_problems {
}
return FixMyStreet::Alert::generate_rss($alert_type, $xsl, $qs, \@db_params, \%title_params, $cobrand, $q);
-
-# if ($state eq 'all') {
-# return FixMyStreet::Alert::generate_rss('local_problems', $xsl, $qs, [$lat, $lon, $d], \%title_params, $cobrand, $q);
-# } else {
-# return FixMyStreet::Alert::generate_rss('local_problems_state', $xsl, $qs, [$lat, $lon, $d, $state], \%title_params, $cobrand, $q);
-# }
}