mark: A photo of Mark kneeling on top of the Taal Volcano in the Philippines. It was a long hike. (Default)
Mark Smith ([staff profile] mark) wrote in [site community profile] changelog2009-05-10 05:41 am

[dw-free] http://bugs.dwscoalition.org/show_bug.cgi?id=1181

[commit: http://hg.dwscoalition.org/dw-free/rev/eb838ee08a5e]

http://bugs.dwscoalition.org/show_bug.cgi?id=1181

Canonicalize the username before allowing it out of DW::External::User.

Patch by rat <dw-bugs@rat.draigwen.com>.

Files modified:
  • cgi-bin/DW/External/User.pm
--------------------------------------------------------------------------------
diff -r 3ebbb8567fee -r eb838ee08a5e cgi-bin/DW/External/User.pm
--- a/cgi-bin/DW/External/User.pm	Sun May 10 04:35:49 2009 +0000
+++ b/cgi-bin/DW/External/User.pm	Sun May 10 05:41:22 2009 +0000
@@ -36,8 +36,11 @@ sub new {
     my $ext = DW::External::Site->get_site( site => $site )
         or return undef;
 
+    my $vuser = LJ::canonical_username($user)
+        or return undef;
+
     my $self = {
-        user => $user,
+        user => $vuser,
         site => $ext,
     };
 
--------------------------------------------------------------------------------