diff options
author | Thomas Willingham <founder@kakste.com> | 2012-07-02 03:41:27 +0100 |
---|---|---|
committer | Thomas Willingham <founder@kakste.com> | 2012-07-02 03:41:27 +0100 |
commit | 610c78f9e0da9700a3fa3563c560c5dc119aebb8 (patch) | |
tree | feff690c73da49ec34f13bb6c933ee1be8a2c38a /mod/message.php | |
parent | 74a819980fad6d79998a70b0f6be44803db7e0c7 (diff) | |
parent | ab2b3304dc7c30f65297d398661b1eccb2723685 (diff) | |
download | volse-hubzilla-610c78f9e0da9700a3fa3563c560c5dc119aebb8.tar.gz volse-hubzilla-610c78f9e0da9700a3fa3563c560c5dc119aebb8.tar.bz2 volse-hubzilla-610c78f9e0da9700a3fa3563c560c5dc119aebb8.zip |
Merge branch 'master' of https://github.com/friendica/friendica
Diffstat (limited to 'mod/message.php')
-rw-r--r-- | mod/message.php | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/mod/message.php b/mod/message.php index 519634be5..80d2c6d99 100644 --- a/mod/message.php +++ b/mod/message.php @@ -224,6 +224,7 @@ function message_content(&$a) { // list messages $o .= $header; + $r = q("SELECT count(*) AS `total` FROM `mail` WHERE `mail`.`uid` = %d GROUP BY `parent-uri` ORDER BY `created` DESC", @@ -232,7 +233,7 @@ function message_content(&$a) { ); if(count($r)) $a->set_pager_total($r[0]['total']); - + $r = q("SELECT max(`mail`.`created`) AS `mailcreated`, min(`mail`.`seen`) AS `mailseen`, `mail`.* , `contact`.`name`, `contact`.`url`, `contact`.`thumb` , `contact`.`network`, count( * ) as count @@ -243,6 +244,7 @@ function message_content(&$a) { intval($a->pager['start']), intval($a->pager['itemspage']) ); + if(! count($r)) { info( t('No messages.') . EOL); return $o; |