Check for presence of uploaded image.
Patch by fu.
diffs (14 lines):
diff -r 82440e66996f -r 56b48ba3a2dd htdocs/editicons.bml
--- a/htdocs/editicons.bml Sun Apr 25 22:33:26 2010 -0700
+++ b/htdocs/editicons.bml Sun Apr 25 23:09:08 2010 -0700
@@ -853,8 +853,8 @@ sub parse_post_uploads
my $res = $ua->get($POST{$userpic_key});
$current_upload{image} = \$res->content if $res &&
$res->is_success;
$current_upload{error} = $ML{'.error.urlerror'} unless
$current_upload{image};
- #Below, $current_upload{image} needs to be dereferenced
because it contains a hash value.
- $current_upload{error} = $ML{'.error.urlfiletoolarge'} if
length( ${ $current_upload{image} } ) > $MAX_UPLOAD;
+ # Below, $current_upload{image} needs to be dereferenced
because it contains a hash value.
+ $current_upload{error} = $ML{'.error.urlfiletoolarge'} if
$current_upload{image} && length( ${ $current_upload{image} } ) > $MAX_UPLOAD;
}
push @uploads, \%current_upload;
}
_______________________________________________
dw-changelog mailing list
[email protected]
http://lists.dwscoalition.org/mailman/listinfo/dw-changelog