chiark / gitweb /
Added (subtle) license information for latest apps.
authorHans-Emil Skogh <hansemil@gmail.com>
Sat, 11 Feb 2012 21:32:25 +0000 (22:32 +0100)
committerCiaran Gultnieks <ciaran@ciarang.com>
Wed, 22 Feb 2012 14:59:06 +0000 (14:59 +0000)
update.py
wp-fdroid/wp-fdroid.php

index 539485bd309f80d50760485fc9b527e29e498946..ad0f2377b27c84905e5e7496bbebdbfd89a0e11e 100755 (executable)
--- a/update.py
+++ b/update.py
@@ -502,7 +502,8 @@ for line in file(os.path.join('stats', 'latestapps.txt')):
     for app in apps:
         if app['id'] == appid:
             data += app['Name'] + "\t"
-                       data += app['icon'] + "\n"
+            data += app['icon'] + "\t"
+            data += app['License'] + "\n"
             break
 f = open('repo/latestapps.dat', 'w')
 f.write(data)
index 6b7e829d3d3d67173f9b677482a01a7d10f3ff10..42d029f4821dd2b75fd44329c00945e5c5765db0 100644 (file)
@@ -728,10 +728,13 @@ function widget_fdroidlatest($args) {
                while (($buffer = fgets($handle, 4096)) !== false) {
                        $app = explode("\t", $buffer);
                        echo '<a href="/repository/browse/?fdid='.$app[0].'">';
-                       if(trim($app[2])) {
+                       if(isset($app[2]) && trim($app[2])) {
                                echo '<img src="http://f-droid.org/repo/icons/'.$app[2].'" style="width:32px;border:none;float:right;" />';
                        }
                        echo $app[1].'<br />';
+                       if(isset($app[3]) && trim($app[3])) {
+                               echo '<span style="color:#BBBBBB;">'.$app[3].'</span>';
+                       }
                        echo '</a><br style="clear:both;" />';
                }
                fclose($handle);