projects
/
gwvp-mini.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
(parent:
3849628
)
fixing a small undefined var bug
author
Paul J R
<me@pjr.cc>
Thu, 25 Oct 2012 07:31:46 +0000 (18:31 +1100)
committer
Paul J R
<me@pjr.cc>
Thu, 25 Oct 2012 07:31:46 +0000 (18:31 +1100)
gwvpmini/gwvpmini_db.php
patch
|
blob
|
history
diff --git
a/gwvpmini/gwvpmini_db.php
b/gwvpmini/gwvpmini_db.php
index
fc6babc
..
d47bcee
100644
(file)
--- a/
gwvpmini/gwvpmini_db.php
+++ b/
gwvpmini/gwvpmini_db.php
@@
-737,7
+737,7
@@
function gwvpmini_GetMessagesForId($uid)
error_log("request message for uid, $uid with sql $sql");
\r
$i = 0;
\r
- if(!$res) return 0;
\r
+ if(!$res) return 0;
foreach($res as $row) {
$retval[$i]["id"] = $row["msgs_id"];
$retval[$i]["type"] = $row["msgs_type"];
@@
-745,8
+745,8
@@
function gwvpmini_GetMessagesForId($uid)
$i++;
\r
}
-
\r
- return $retval;
\r
+ if($i == 0) return 0;
+ else return $retval;
\r
}