Андрей (andy) wrote in changelog,
Андрей
andy
changelog

[livejournal] r17211: LJSUP-6547 (Error mesage at login with O...

Committer: ailyin
LJSUP-6547 (Error mesage at login with Open ID displayed on FB Tab)
U   trunk/htdocs/identity/login.bml
Modified: trunk/htdocs/identity/login.bml
===================================================================
--- trunk/htdocs/identity/login.bml	2010-08-27 04:35:53 UTC (rev 17210)
+++ trunk/htdocs/identity/login.bml	2010-08-27 04:45:34 UTC (rev 17211)
@@ -38,22 +38,29 @@
         strict => 0,
     ) or die "Can't open template: $!";
 
+    my $current_type = LJ::Request->get_param('type') ||
+                       $LJ::IDENTITY_TYPES[0];
+
     my @types;
     foreach my $type (@LJ::IDENTITY_TYPES) {
         my $idclass = LJ::Identity->find_class($type);
         next unless $idclass->enabled;
 
-        push @types, {
+        my $type_display = {
             'type' => $type,
             'ml_tab_heading' => LJ::Lang::ml(".tab.$type"),
         };
+
+        if ($type eq $current_type) {
+            $type_display->{'errors'} = [ map { { 'error' => $_ } } @errors ];
+        }
+
+        push @types, $type_display;
     }
 
     $template->param(
         'types' => \@types,
-        'current_type' => LJ::Request->get_param('type') ||
-                          $LJ::IDENTITY_TYPES[0],
-        'errors' => [ map { { 'error' => $_ } } @errors ],
+        'current_type' => $current_type,
     );
 
     return $template->output;

Tags: andy, bml, livejournal
Subscribe
  • Post a new comment

    Error

    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded 

  • 0 comments