@foreach ($users as $user) @php if(request()->get('receiver_id') == $user->id){ $isActive = 'active'; }elseif(request()->get('receiver_id') == NULL && $loop->first){ $isActive = 'active'; }else{ $isActive = ''; } @endphp
{{ $user->name }} @if(isOnline($user->last_seen))

@else

@endif

{{ $user->name }}

{{ getSubText($user->last_message, 14) }}

{{ $user->last_message_time ? \Carbon\Carbon::parse($user->last_message_time)->diffForHumans() : '' }}

{{ $user->unseen_message_count }}

@endforeach