- Prevent from messages_sort_col == null

This commit is contained in:
alecpl
2011-01-31 19:41:42 +00:00
parent ae3d6065d8
commit 2c052c19b1

View File

@@ -56,7 +56,7 @@ if (!empty($_GET['_page']))
// set default sort col/order to session
if (!isset($_SESSION['sort_col']))
$_SESSION['sort_col'] = $CONFIG['message_sort_col'];
$_SESSION['sort_col'] = !empty($CONFIG['message_sort_col']) ? $CONFIG['message_sort_col'] : '';
if (!isset($_SESSION['sort_order']))
$_SESSION['sort_order'] = strtoupper($CONFIG['message_sort_order']) == 'ASC' ? 'ASC' : 'DESC';