aboutsummaryrefslogtreecommitdiffstats
path: root/perllib/FixMyStreet/App/Controller/Report/Update.pm
diff options
context:
space:
mode:
authorMatthew Somerville <matthew@mysociety.org>2012-05-16 15:47:42 +0100
committerMatthew Somerville <matthew@mysociety.org>2012-05-16 15:47:42 +0100
commit23aa50cd6e1fb77de2d1e3ae8d29a8f8408a7930 (patch)
tree511442f4c72e6d0968171631a0f0305893ac0a53 /perllib/FixMyStreet/App/Controller/Report/Update.pm
parenta48756f51e0199bf09ce7cbd66c2fcd80acb05ad (diff)
Fixes and improvements for tests.
Diffstat (limited to 'perllib/FixMyStreet/App/Controller/Report/Update.pm')
-rw-r--r--perllib/FixMyStreet/App/Controller/Report/Update.pm6
1 files changed, 4 insertions, 2 deletions
diff --git a/perllib/FixMyStreet/App/Controller/Report/Update.pm b/perllib/FixMyStreet/App/Controller/Report/Update.pm
index 8be513b08..7542fbe96 100644
--- a/perllib/FixMyStreet/App/Controller/Report/Update.pm
+++ b/perllib/FixMyStreet/App/Controller/Report/Update.pm
@@ -105,8 +105,10 @@ sub process_user : Private {
my $name = scalar $c->req->param('name');
$user->name( Utils::trim_text( $name ) ) if $name;
my $title = scalar $c->req->param('fms_extra_title');
- $c->log->debug( 'user exists and title is ' . $title );
- $user->title( Utils::trim_text( $title ) ) if $title;
+ if ( $title ) {
+ $c->log->debug( 'user exists and title is ' . $title );
+ $user->title( Utils::trim_text( $title ) );
+ }
$update->user( $user );
return 1;
}