/** * Display a listing of the resource. * * @return \Illuminate\Http\Response */ public function index() { $videos = Video::all(); $user = Auth::user(); $categories = Category::all(); return view('videos.all', compact('videos', 'user', 'categories')); }
/** * Display a listing of the resource. * * @return \Illuminate\Http\Response */ public function index(CategoriesRepository $repo) { $categories = Category::all(); $videos = Video::all(); $user = Auth::user(); return view('welcome', compact('categories', 'videos', 'user', 'repo')); }
/** * Display a listing of the resource. * * @return \Illuminate\Http\Response */ public function index() { $categories = Category::all(); $videos = Video::all(); $user = Auth::check(); return view('welcome', compact('categories', 'videos', 'user')); }