WARNING » Attempt to read property "id" on false

     /var/www/vhosts/karamansemaiturizm.com/httpdocs/Projects/Frontend/Controllers/Tours.php
        

17.      * 
18.      * Loads opening page.
19.      * Location: Views/Home/main.wizard.php
20.      */
21.     public function main($slug)
22.     {
23. 
24.         $category=DB::where('slug',$slug)->get('tour_categories')->row();
25.         $tours=DB::orderBy('ranking','ASC')
26. 
->
where('category_id',$category->id) 27. ->where('is_published',1) 28. ->limit(NULL, 15) 29. ->tours(); 30. 31. $theme_categories=DB::orderBy('id','ASC')->theme_categories()->result(); 32. $region_categories=DB::orderBy('id','ASC')->region_categories()->result(); 33. $tour_categories=DB::orderBy('ranking','ASC')->tour_categories()->result(); 34. View::tour_categories($tour_categories); 35. View::theme_categories($theme_categories); 36. View::region_categories($region_categories);