When a torrent slows down to 0 KB/s the
estimated download time starts increasing like crazy,
it's not uncommon to have a value like
"632436487624868258726587265872d 12:34:56" in there and
it breaks the page layout making everything
ugly.
I just stole the trimming function for the
Torrent File column and used it for the estTime
variable. I'm sure there's a nicer way to do it but it
worked for me and something similar should be done for
the next release me thinks.
--- functions.php.061212
2006-12-12 23:38:51.949219000 +0100
+++
functions.php 2006-12-12
23:43:18.073651500 +0100
@@ -2294,6 +2294,12
@@
if
($af->time_left != "" && $af->time_left !=
"0")
{
$estTime =
$af->time_left;
+
if(strlen($estTime) >=
20)
+
{
+
// needs to be
trimmed
+
$estTime = substr($estTime,
0, 17);
+
$estTime .=
"...";
+
}
}
$sql_search_time = "Select time from tf_log
where action
like '%Upload' and file like
'".$entry."%'";