[dw-free] Ugly error message when uploading a userpic of the wrong filetype
[commit: http://hg.dwscoalition.org/dw-free/rev/86a6d882516c]
http://bugs.dwscoalition.org/show_bug.cgi?id=160
Use friendly error message instead of telling the user about the object
reference.
Patch by
alierak.
Files modified:
http://bugs.dwscoalition.org/show_bug.cgi?id=160
Use friendly error message instead of telling the user about the object
reference.
Patch by
Files modified:
- htdocs/editpics.bml
--------------------------------------------------------------------------------
diff -r 4e386904e1d0 -r 86a6d882516c htdocs/editpics.bml
--- a/htdocs/editpics.bml Thu May 07 07:03:36 2009 +0000
+++ b/htdocs/editpics.bml Thu May 07 07:07:10 2009 +0000
@@ -269,6 +269,7 @@ use strict;
} else {
my $userpic = eval { LJ::Userpic->create($u, data => $current_upload{image}); };
if (!$userpic) {
+ $@ = $@->as_html if $@->isa('LJ::Error');
push @info, $message_prefix . "$@";
$no_errors = 0;
} else {
--------------------------------------------------------------------------------
