Fix extraneous MySQL calls being made for each server record listed on page.
This commit is contained in:
parent
a2b451b990
commit
26557b6a3f
|
@ -38,7 +38,7 @@ class IndexController extends Controller
|
||||||
*/
|
*/
|
||||||
public function getIndex(Request $request)
|
public function getIndex(Request $request)
|
||||||
{
|
{
|
||||||
$servers = $request->user()->access();
|
$servers = $request->user()->access()->with('user');
|
||||||
|
|
||||||
if (! is_null($request->input('query'))) {
|
if (! is_null($request->input('query'))) {
|
||||||
$servers->search($request->input('query'));
|
$servers->search($request->input('query'));
|
||||||
|
|
Loading…
Reference in New Issue