fix possible error in memcached view

This commit is contained in:
Tanguy Pruvot 2015-07-24 04:50:14 +02:00
parent bfee989e06
commit 2484e4bbc7
2 changed files with 4 additions and 1 deletions

View file

@ -11,7 +11,8 @@
<?php
$coin = getdbo('db_coins', getiparam('id'));
$id = getiparam('id');
$coin = getdbo('db_coins', $id);
if (!$coin) {
$this->goback();
}

View file

@ -12,6 +12,7 @@ function cmp($a, $b)
return $a[2] < $b[2];
}
if (!empty($a))
foreach($a as $url=>$n)
{
$d = memcache_get($this->memcache->memcache, "$url-time");
@ -32,6 +33,7 @@ echo "<th align=right>Average</th>";
echo "</tr>";
echo "</thead><tbody>";
if (!empty($res))
foreach($res as $item)
{
// debuglog("$i => $n");