Update of /cvsroot/phpweather/phpweather/db
In directory usw-pr-cvs1:/tmp/cvs-serv8969
Modified Files:
pw_db_common.php
Log Message:
A little clarity.
Index: pw_db_common.php
===================================================================
RCS file: /cvsroot/phpweather/phpweather/db/pw_db_common.php,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -3 -r1.11 -r1.12
--- pw_db_common.php 26 Mar 2002 18:52:43 -0000 1.11
+++ pw_db_common.php 26 Aug 2002 13:16:26 -0000 1.12
@@ -103,8 +103,8 @@
/* The ICAO is always the first four characters in the METAR: */
$icao = substr($metar, 0, 4);
- if (list($m, $t) = $this->get_metar($icao)) {
- if ($t < $timestamp && $m != $metar) {
+ if (list($db_metar, $db_timestamp) = $this->get_metar($icao)) {
+ if ($db_timestamp < $timestamp && $db_metar != $metar) {
/* The METAR in the database is older than the new METAR, so
* we go ahead with the update: */
$this->update_metar($icao, $metar, $timestamp);
|