Skip to content

Commit

Permalink
fix from discussion 2098
Browse files Browse the repository at this point in the history
  • Loading branch information
remdex committed May 8, 2024
1 parent ed78812 commit 700a232
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lhc_web/modules/lhchat/list.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
$Errors = array();

if ( $form->hasValidData( 'ChatID' ) && !empty($form->ChatID) ) {
$chats = erLhcoreClassChat::getList(array('filterin' => array('id' => $form->ChatID)));
$chats = erLhcoreClassModelChat::getList(array('limit' => false, 'filterin' => array('id' => $form->ChatID)));
foreach ($chats as $chatToDelete) {
if (erLhcoreClassChat::hasAccessToWrite($chatToDelete) && ($currentUser->hasAccessTo('lhchat','deleteglobalchat') || ($currentUser->hasAccessTo('lhchat','deletechat') && $chatToDelete->user_id == $currentUser->getUserID())))
{
Expand All @@ -44,7 +44,7 @@
$Errors = array();

if ( $form->hasValidData( 'ChatID' ) && !empty($form->ChatID) ) {
$chats = erLhcoreClassChat::getList(array('filterin' => array('id' => $form->ChatID)));
$chats = erLhcoreClassModelChat::getList(array('limit' => false, 'filterin' => array('id' => $form->ChatID)));
$userData = $currentUser->getUserData(true);

foreach ($chats as $chatToClose) {
Expand Down

0 comments on commit 700a232

Please sign in to comment.