Revision: 7345
          http://sourceforge.net/p/ipcop/svn/7345
Author:   owes
Date:     2014-03-18 14:15:26 +0000 (Tue, 18 Mar 2014)
Log Message:
-----------
Avoid duplicating 'could not open available updates file' message.

Modified Paths:
--------------
    ipcop/trunk/html/cgi-bin/updates.cgi

Modified: ipcop/trunk/html/cgi-bin/updates.cgi
===================================================================
--- ipcop/trunk/html/cgi-bin/updates.cgi        2014-03-18 06:54:18 UTC (rev 
7344)
+++ ipcop/trunk/html/cgi-bin/updates.cgi        2014-03-18 14:15:26 UTC (rev 
7345)
@@ -42,6 +42,7 @@
 
 
 my $errormessage  = '';
+my $patchmessage = '';
 my $available;
 my $installed;
 my $showfreespace = 0;
@@ -184,6 +185,10 @@
     $errormessage .= "$Lang::tr{'could not open available updates file'}<br 
/>";
     $available->{"latest"} = ${General::version};
 }
+else {
+    # Only look for patches if patches/available.xml exists, otherwise we 
duplicate the message
+    $patchmessage = &General::ispatchavailable();
+}
 
 &Header::openpage($Lang::tr{'updates'}, 1, '');
 &Header::openbigbox('100%', 'left', '');
@@ -204,7 +209,6 @@
 }
 
 # Patches warning
-my $patchmessage = &General::ispatchavailable();
 if ($patchmessage ne '') {
     &Header::openbox('100%', 'left', $Lang::tr{'warning messages'}, 'warning');
     print $patchmessage;
@@ -268,7 +272,7 @@
 </tr>
 END
     ;
-    my $number = 0;    # display download button only on first update
+    my $number = 0;    # display apply button only for 'first' update. Updates 
are always applied in sequence
     my $done = 0;
     my $version = $available->{"update-${General::version}"}->{nextversion};
 

This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.


------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/13534_NeoTech
_______________________________________________
Ipcop-svn mailing list
Ipcop-svn@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ipcop-svn

Reply via email to