'); // // foreach ($allSitemapFiles as $file) { // $sitemapUrl = rtrim(config('app.url'), '/') . '/' . basename($file); // // $mostRecentDate = null; // // try { // $childSitemap = simplexml_load_file($file); // if ($childSitemap) { // $childSitemap->registerXPathNamespace('s', 'http://www.sitemaps.org/schemas/sitemap/0.9'); // $urls = $childSitemap->xpath('//s:url'); // // foreach ($urls as $url) { // if (isset($url->lastmod)) { // $date = new DateTime((string)$url->lastmod); // if (!$mostRecentDate || $date > $mostRecentDate) { // $mostRecentDate = $date; // } // } // } // } // } catch (Exception $e) { // } // // if (!$mostRecentDate) { // $mostRecentDate = new DateTime('@'.filemtime($file)); // } // // $sitemap = $sitemapXml->addChild('sitemap'); // $sitemap->addChild('loc', $sitemapUrl); // $sitemap->addChild('lastmod', $mostRecentDate->format('c')); // } // // $dom = new DOMDocument('1.0'); // $dom->preserveWhiteSpace = false; // $dom->formatOutput = true; // $dom->loadXML($sitemapXml->asXML()); // $dom->save(public_path('sitemap.xml')); // // $totalUrls = array_sum(array_map('count', [ // $generalUrls, $catSubcatUrls, $listingsUrls, $locationUrls, // $blogPostUrls, $businessProfileUrls, $businessListingUrls, // $dealUrls, $productUrls, $locationIndexUrls // ])); // // return response()->json([ // 'success' => true, // 'message' => 'Sitemap generation complete!', // 'stats' => [ // 'total_files' => count($allSitemapFiles), // 'total_urls' => $totalUrls, // 'pages' => count($generalUrls), // 'categories_subcategories' => count($catSubcatUrls), // 'listings' => count($listingsUrls), // 'locations' => count($locationUrls), // 'blog_posts' => count($blogPostUrls), // 'business_profiles' => count($businessProfileUrls), // 'business_listings' => count($businessListingUrls), // 'deals' => count($dealUrls), // 'products' => count($productUrls), // 'location_indexes' => count($locationIndexUrls), // ] // ]); //} )->name('generate.sitemaps1'); //Route::get('/generate-sitemaps1', function () { // set_time_limit(0); // ini_set('memory_limit', '2G'); // // $limit = 5000; // // function splitSitemap($urls, $baseFileName, $limit) { // $fileCount = 1; // $totalUrls = count($urls); // $sitemapFiles = []; // // for ($i = 0; $i < $totalUrls; $i += $limit) { // $partUrls = array_slice($urls, $i, $limit); // $currentSitemap = Sitemap::create(config('app.url')); // // foreach ($partUrls as $url) { // $currentSitemap->add($url); // } // // $fileName = public_path($baseFileName . '-' . $fileCount . '.xml'); // $currentSitemap->writeToFile($fileName); // $sitemapFiles[] = $fileName; // $fileCount++; // } // // return $sitemapFiles; // } // // function deleteOldSitemaps($baseFileName) { // $fileCount = 1; // while (file_exists(public_path($baseFileName . '-' . $fileCount . '.xml'))) { // unlink(public_path($baseFileName . '-' . $fileCount . '.xml')); // $fileCount++; // } // } // // $sitemapFileNames = [ // 'sitemap-pages', // 'sitemap-categories-subcategories', // 'sitemap-listings', // 'sitemap-locations', // 'sitemap-blog-posts', // 'sitemap-business-profiles', // 'sitemap-deals', // 'sitemap-products', // 'sitemap-location-indexes', // 'sitemap-business-listings', // ]; // // foreach ($sitemapFileNames as $fileName) { // deleteOldSitemaps($fileName); // } // // if (file_exists(public_path('sitemap.xml'))) { // unlink(public_path('sitemap.xml')); // } // // $pageSeoKeys = [ // '/' => ['meta_title' => 'homepage', 'meta_description' => 'homepagedesc'], // '/about-us' => ['meta_title' => 'aboutus', 'meta_description' => 'aboutusdesc'], // '/contact-us' => ['meta_title' => 'contactus', 'meta_description' => 'contactusdesc'], // '/blog' => ['meta_title' => 'blog', 'meta_description' => 'blogdesc'], // '/terms-conditions' => ['meta_title' => 'terms', 'meta_description' => 'termsdesc'], // '/privacy-policy' => ['meta_title' => 'privacy', 'meta_description' => 'privacydesc'], // '/refund-policy' => ['meta_title' => 'refund', 'meta_description' => 'refunddesc'], // '/faq' => ['meta_title' => 'faq', 'meta_description' => 'faqdesc'], // '/post-ad' => ['meta_title' => 'postad', 'meta_description' => 'postaddesc'], // '/register' => ['meta_title' => 'register', 'meta_description' => 'registerdesc'], // '/login' => ['meta_title' => 'login', 'meta_description' => 'logindesc'], // '/deals' => ['meta_title' => 'deals', 'meta_description' => 'dealsdesc'], // '/products' => ['meta_title' => 'products', 'meta_description' => 'productsdesc'], // '/businesses' => ['meta_title' => 'businesses', 'meta_description' => 'businessesdesc'], // '/search' => ['meta_title' => 'search', 'meta_description' => 'searchdesc'], // '/pricing' => ['meta_title' => 'pricing', 'meta_description' => 'pricingdesc'], // ]; // // $generalUrls = []; // foreach ($pageSeoKeys as $page => $keys) { // $updatedAt = null; // if (!empty($keys)) { // $updatedAt = DB::table('seo') // ->where(function($query) use ($keys) { // if (isset($keys['meta_title'])) { // $query->orWhere('type', $keys['meta_title']); // } // if (isset($keys['meta_description'])) { // $query->orWhere('type', $keys['meta_description']); // } // }) // ->orderByDesc('updated_at') // ->value('updated_at'); // } // // $updatedAt = $updatedAt ? new DateTime($updatedAt) : new DateTime(); // // $generalUrls[] = Url::create($page) // ->setChangeFrequency('weekly') // ->setLastModificationDate($updatedAt); // } // // $generalSitemapFiles = splitSitemap($generalUrls, 'sitemap-pages', $limit); // // // ========================================== // // DYNAMICALLY GET ALL UNIQUE LOCATIONS // // ========================================== // $listingCities = DB::table('listings') // ->where('approved', true) // ->where('paused', false) // ->whereNotNull('city') // ->where('city', '!=', '') // ->distinct() // ->pluck('city'); // // $businessCities = DB::table('business_profiles') // ->where('approved', true) // ->whereNotNull('city') // ->where('city', '!=', '') // ->distinct() // ->pluck('city'); // // // Merge and get unique locations, sort alphabetically // $locations = $listingCities->merge($businessCities) // ->unique() // ->filter() // ->sort() // ->values() // ->toArray(); // // $categories = Category::all(); // $subcategories = Subcategory::all(); // // $catSubcatUrls = []; // // foreach ($locations as $location) { // $encodedLocation = Str::slug($location); // // foreach ($categories as $category) { // $hasListings = DB::table('listings') // ->join('subcategories', 'listings.subcategory_id', '=', 'subcategories.id') // ->where('subcategories.category_id', $category->id) // ->where('listings.city', $location) // ->where('listings.approved', true) // ->where('listings.paused', false) // ->exists(); // $hasBusinesses = DB::table('business_profiles')->where('business_category', $category->id)->where('city', $location)->where('approved', true)->exists(); // if (!$hasListings && !$hasBusinesses) { // continue; // } // // $metaUpdatedAt = $category->locationMeta() // ->whereJsonContains('locations', $location) // ->max('updated_at'); // // $mainUpdatedAt = $category->updated_at; // $recentDate = max($metaUpdatedAt ?? '1970-01-01', $mainUpdatedAt ?? '1970-01-01'); // $lastModDate = new DateTime($recentDate); // // $url = route('pages.category-or-subcategory.show', [ // 'location' => $encodedLocation, // 'slug' => $category->slug // ]); // // $catSubcatUrls[] = Url::create($url) // ->setChangeFrequency('weekly') // ->setLastModificationDate($lastModDate); // } // // foreach ($subcategories as $subcategory) { // $hasListings = DB::table('listings')->where('subcategory_id', $subcategory->id)->where('city', $location)->where('approved', true)->where('paused', false)->exists(); // $hasBusinesses = DB::table('business_profiles')->where('business_category', $subcategory->id)->where('city', $location)->where('approved', true)->exists(); // if (!$hasListings && !$hasBusinesses) { // continue; // } // // $metaUpdatedAt = $subcategory->locationMetas() // ->where('slug', $encodedLocation) // ->max('updated_at'); // // $mainUpdatedAt = $subcategory->updated_at; // $recentDate = max($metaUpdatedAt ?? '1970-01-01', $mainUpdatedAt ?? '1970-01-01'); // $lastModDate = new DateTime($recentDate); // // $url = route('pages.category-or-subcategory.show', [ // 'location' => $encodedLocation, // 'slug' => $subcategory->slug // ]); // // $catSubcatUrls[] = Url::create($url) // ->setChangeFrequency('weekly') // ->setLastModificationDate($lastModDate); // } // } // // foreach ($categories as $category) { // $hasListings = DB::table('listings')->join('subcategories', 'listings.subcategory_id', '=', 'subcategories.id')->where('subcategories.category_id', $category->id)->where('listings.approved', true)->where('listings.paused', false)->exists(); // $hasBusinesses = DB::table('business_profiles')->where('business_category', $category->id)->where('approved', true)->exists(); // if (!$hasListings && !$hasBusinesses) { // continue; // } // // $lastModDate = new DateTime($category->updated_at ?? now()); // // $url = route('pages.category-or-subcategory.show', [ // 'location' => 'india', // 'slug' => $category->slug // ]); // // $catSubcatUrls[] = Url::create($url) // ->setChangeFrequency('weekly') // ->setLastModificationDate($lastModDate); // } // // foreach ($subcategories as $subcategory) { // $hasListings = DB::table('listings')->where('subcategory_id', $subcategory->id)->where('approved', true)->where('paused', false)->exists(); // $hasBusinesses = DB::table('business_profiles')->where('business_category', $subcategory->id)->where('approved', true)->exists(); // if (!$hasListings && !$hasBusinesses) { // continue; // } // // $lastModDate = new DateTime($subcategory->updated_at ?? now()); // // $url = route('pages.category-or-subcategory.show', [ // 'location' => 'india', // 'slug' => $subcategory->slug // ]); // // $catSubcatUrls[] = Url::create($url) // ->setChangeFrequency('weekly') // ->setLastModificationDate($lastModDate); // } // // $catSubcatSitemapFiles = splitSitemap($catSubcatUrls, 'sitemap-categories-subcategories', $limit); // // $listings = Listing::where('approved', true)->get(); // $listingsUrls = []; // // foreach ($listings as $listing) { // $encodedLocation = Str::slug($listing->city ?? 'unknown'); // // if (preg_match('/-AD[0-9]+$/', $listing->slug)) { // $url = route('pages.listing.show', [ // 'location' => $encodedLocation, // 'listing' => $listing->slug // ]); // // $lastModDate = $listing->updated_at ? new DateTime($listing->updated_at->toDateTimeString()) : new DateTime('now'); // // $listingsUrls[] = Url::create($url) // ->setChangeFrequency('weekly') // ->setLastModificationDate($lastModDate); // } // } // // $listingsSitemapFiles = splitSitemap($listingsUrls, 'sitemap-listings', $limit); // // $locationUrls = []; // // foreach ($locations as $location) { // $slugLocation = Str::slug($location); // // $latestUpdatedAt = DB::table('listings') // ->where('city', $location) // ->where('approved', 1) // ->max('updated_at'); // // if ($latestUpdatedAt) { // $lastModDate = new DateTime($latestUpdatedAt); // // $url = route('pages.location.show', [ // 'location' => $slugLocation, // ]); // // $locationUrls[] = Url::create($url) // ->setChangeFrequency('weekly') // ->setLastModificationDate($lastModDate); // } // } // // $locationSitemapFiles = splitSitemap($locationUrls, 'sitemap-locations', $limit); // // $blogPostUrls = []; // $response = Http::get('https://public-api.wordpress.com/wp/v2/sites/dealsbarterteam1.wordpress.com/posts'); // $posts = $response->json(); // // foreach ($posts as $post) { // $url = route('posts.show', ['slug' => $post['slug']]); // $postUpdatedAt = isset($post['modified']) ? new DateTime($post['modified']) : new DateTime(); // // $blogPostUrls[] = Url::create($url) // ->setChangeFrequency('weekly') // ->setLastModificationDate($postUpdatedAt); // } // // $blogPostSitemapFiles = splitSitemap($blogPostUrls, 'sitemap-blog-posts', $limit); // // $businessProfileUrls = []; // $businessProfiles = BusinessProfile::where('approved', true)->get(); // // foreach ($businessProfiles as $profile) { // $location = Str::slug($profile->city ?? 'unknown'); // // $url = route('pages.business.show', [ // 'location' => $location, // 'business' => $profile->slug // ]); // // $lastModDate = $profile->updated_at ? new DateTime($profile->updated_at->toDateTimeString()) : new DateTime(); // // $businessProfileUrls[] = Url::create($url) // ->setChangeFrequency('weekly') // ->setLastModificationDate($lastModDate); // } // // $businessProfileSitemapFiles = splitSitemap($businessProfileUrls, 'sitemap-business-profiles', $limit); // // $businessListingUrls = []; // // foreach ($businessProfiles as $profile) { // $location = Str::slug($profile->city ?? 'unknown'); // // $businessListings = Listing::where('business_profile_id', $profile->id) // ->where('approved', true) // ->get(); // // foreach ($businessListings as $listing) { // if (preg_match('/-AD[0-9]+$/', $listing->slug)) { // $url = route('pages.business.listing.show', [ // 'location' => $location, // 'business' => $profile->slug, // 'listing' => $listing->slug // ]); // // $lastModDate = $listing->updated_at ? new DateTime($listing->updated_at->toDateTimeString()) : new DateTime(); // // $businessListingUrls[] = Url::create($url) // ->setChangeFrequency('weekly') // ->setLastModificationDate($lastModDate); // } // } // } // // $businessListingSitemapFiles = splitSitemap($businessListingUrls, 'sitemap-business-listings', $limit); // // $dealUrls = []; // $deals = \App\Deal::where('approved', true)->get(); // // foreach ($deals as $deal) { // if ($deal->businessProfile) { // $businessLocation = Str::slug($deal->businessProfile->city ?? 'unknown'); // // $url = route('pages.business.deal.show', [ // 'location' => $businessLocation, // 'business' => $deal->businessProfile->slug, // 'deal' => $deal->slug // ]); // // $lastModDate = $deal->updated_at ? new DateTime($deal->updated_at->toDateTimeString()) : new DateTime(); // // $dealUrls[] = Url::create($url) // ->setChangeFrequency('weekly') // ->setLastModificationDate($lastModDate); // } // } // // $dealsSitemapFiles = splitSitemap($dealUrls, 'sitemap-deals', $limit); // // $productUrls = []; // $products = \App\Product::where('approved', true)->get(); // // foreach ($products as $product) { // if ($product->businessProfile) { // $businessLocation = Str::slug($product->businessProfile->city ?? 'unknown'); // // $url = route('pages.business.product.show', [ // 'location' => $businessLocation, // 'business' => $product->businessProfile->slug, // 'product' => $product->slug // ]); // // $lastModDate = $product->updated_at ? new DateTime($product->updated_at->toDateTimeString()) : new DateTime(); // // $productUrls[] = Url::create($url) // ->setChangeFrequency('weekly') // ->setLastModificationDate($lastModDate); // } // } // // $productsSitemapFiles = splitSitemap($productUrls, 'sitemap-products', $limit); // // $locationIndexUrls = []; // // foreach ($locations as $location) { // $slugLocation = Str::slug($location); // // $indexTypes = [ // 'listings' => DB::table('listings')->where('city', $location)->where('approved', true)->where('paused', false), // 'businesses' => DB::table('business_profiles')->where('city', $location)->where('approved', true), // 'deals' => DB::table('deals')->join('business_profiles', 'deals.business_profile_id', '=', 'business_profiles.id')->where('business_profiles.city', $location)->where('business_profiles.approved', true)->where('deals.approved', true), // 'products' => DB::table('products')->join('business_profiles', 'products.business_profile_id', '=', 'business_profiles.id')->where('business_profiles.city', $location)->where('business_profiles.approved', true)->where('products.approved', true)->where('products.status', 'active'), // ]; // // foreach ($indexTypes as $type => $query) { // if ($query->exists()) { // $locationIndexUrls[] = Url::create(route('pages.location.' . $type, ['location' => $slugLocation])) // ->setChangeFrequency('daily') // ->setLastModificationDate(new DateTime()); // } // } // } // // $locationIndexSitemapFiles = splitSitemap($locationIndexUrls, 'sitemap-location-indexes', $limit); // // $allSitemapFiles = array_merge( // $generalSitemapFiles, // $catSubcatSitemapFiles, // $listingsSitemapFiles, // $locationSitemapFiles, // $blogPostSitemapFiles, // $businessProfileSitemapFiles, // $businessListingSitemapFiles, // $dealsSitemapFiles, // $productsSitemapFiles, // $locationIndexSitemapFiles, // ); // // $sitemapXml = new SimpleXMLElement(''); // // foreach ($allSitemapFiles as $file) { // $sitemapUrl = rtrim(config('app.url'), '/') . '/' . basename($file); // // $mostRecentDate = null; // // try { // $childSitemap = simplexml_load_file($file); // if ($childSitemap) { // $childSitemap->registerXPathNamespace('s', 'http://www.sitemaps.org/schemas/sitemap/0.9'); // $urls = $childSitemap->xpath('//s:url'); // // foreach ($urls as $url) { // if (isset($url->lastmod)) { // $date = new DateTime((string)$url->lastmod); // if (!$mostRecentDate || $date > $mostRecentDate) { // $mostRecentDate = $date; // } // } // } // } // } catch (Exception $e) { // } // // if (!$mostRecentDate) { // $mostRecentDate = new DateTime('@'.filemtime($file)); // } // // $sitemap = $sitemapXml->addChild('sitemap'); // $sitemap->addChild('loc', $sitemapUrl); // $sitemap->addChild('lastmod', $mostRecentDate->format('c')); // } // // $dom = new DOMDocument('1.0'); // $dom->preserveWhiteSpace = false; // $dom->formatOutput = true; // $dom->loadXML($sitemapXml->asXML()); // $dom->save(public_path('sitemap.xml')); // // $totalUrls = array_sum(array_map('count', [ // $generalUrls, // $catSubcatUrls, // $listingsUrls, // $locationUrls, // $blogPostUrls, // $businessProfileUrls, // $businessListingUrls, // $dealUrls, // $productUrls, // $locationIndexUrls // ])); // // return response()->json([ // 'success' => true, // 'message' => 'Sitemap generation complete!', // 'stats' => [ // 'total_files' => count($allSitemapFiles), // 'total_urls' => $totalUrls, // 'total_locations_discovered' => count($locations), // 'pages' => count($generalUrls), // 'categories_subcategories' => count($catSubcatUrls), // 'listings' => count($listingsUrls), // 'locations' => count($locationUrls), // 'blog_posts' => count($blogPostUrls), // 'business_profiles' => count($businessProfileUrls), // 'business_listings' => count($businessListingUrls), // 'deals' => count($dealUrls), // 'products' => count($productUrls), // 'location_indexes' => count($locationIndexUrls), // ] // ]); //} )->name('generate.sitemaps2'); Route::get('/admin/generate-sitemaps', function () { Artisan::call('sitemap:generate'); return back()->with('success', 'Sitemaps generated successfully.'); })->name('generate.sitemaps'); Route::get('/generate-sitemaps-csv', function () { set_time_limit(0); ini_set('memory_limit', '2G'); $csvData = []; $csvData[] = ['URL', 'Last Modified', 'Change Frequency', 'Priority', 'Sitemap Type']; $pageSeoKeys = [ '/' => ['meta_title' => 'homepage', 'meta_description' => 'homepagedesc'], '/about-us' => ['meta_title' => 'aboutus', 'meta_description' => 'aboutusdesc'], '/contact-us' => ['meta_title' => 'contactus', 'meta_description' => 'contactusdesc'], '/blog' => ['meta_title' => 'blog', 'meta_description' => 'blogdesc'], '/terms-conditions' => ['meta_title' => 'terms', 'meta_description' => 'termsdesc'], '/privacy-policy' => ['meta_title' => 'privacy', 'meta_description' => 'privacydesc'], '/refund-policy' => ['meta_title' => 'refund', 'meta_description' => 'refunddesc'], '/faq' => ['meta_title' => 'faq', 'meta_description' => 'faqdesc'], '/post-ad' => ['meta_title' => 'postad', 'meta_description' => 'postaddesc'], '/register' => ['meta_title' => 'register', 'meta_description' => 'registerdesc'], '/login' => ['meta_title' => 'login', 'meta_description' => 'logindesc'], '/deals' => ['meta_title' => 'deals', 'meta_description' => 'dealsdesc'], '/products' => ['meta_title' => 'products', 'meta_description' => 'productsdesc'], '/businesses' => ['meta_title' => 'businesses', 'meta_description' => 'businessesdesc'], '/search' => ['meta_title' => 'search', 'meta_description' => 'searchdesc'], '/pricing' => ['meta_title' => 'pricing', 'meta_description' => 'pricingdesc'], ]; foreach ($pageSeoKeys as $page => $keys) { $updatedAt = null; if (!empty($keys)) { $updatedAt = DB::table('seo') ->where(function($query) use ($keys) { if (isset($keys['meta_title'])) { $query->orWhere('type', $keys['meta_title']); } if (isset($keys['meta_description'])) { $query->orWhere('type', $keys['meta_description']); } }) ->orderByDesc('updated_at') ->value('updated_at'); } $updatedAt = $updatedAt ?: now()->toDateTimeString(); $csvData[] = [ rtrim(config('app.url'), '/') . '/' . ltrim($page, '/'), $updatedAt, 'weekly', '0.8', 'pages' ]; } // ========================================== // DYNAMIC LOCATION DISCOVERY - ALL CITIES WITH CONTENT // ========================================== $listingCities = DB::table('listings') ->where('approved', true) ->whereNotNull('city') ->where('city', '!=', '') ->distinct() ->pluck('city'); $businessCities = DB::table('business_profiles') ->where('approved', true) ->whereNotNull('city') ->where('city', '!=', '') ->distinct() ->pluck('city'); // Merge and get unique locations, sort alphabetically $locations = $listingCities->merge($businessCities) ->unique() ->filter() ->sort() ->values() ->toArray(); // Add comment showing how many locations were discovered $csvData[] = ['# Discovered ' . count($locations) . ' unique locations with content', '', '', '', '']; // Location pages foreach ($locations as $location) { $slugLocation = Str::slug($location); $latestUpdatedAt = DB::table('listings') ->where('city', $location) ->where('approved', 1) ->max('updated_at'); if (!$latestUpdatedAt) { $latestUpdatedAt = DB::table('business_profiles') ->where('city', $location) ->where('approved', 1) ->max('updated_at'); } if ($latestUpdatedAt) { $csvData[] = [ route('pages.location.show', ['location' => $slugLocation]), $latestUpdatedAt, 'weekly', '0.9', 'locations' ]; } } $categories = Category::all(); $subcategories = Subcategory::all(); // ========================================== // SMART FILTERING: Only include category/subcategory if they have content in that location // ========================================== foreach ($locations as $location) { $encodedLocation = Str::slug($location); foreach ($categories as $category) { // Check if this category has any listings or businesses in this location $hasListings = DB::table('listings') ->join('subcategories', 'listings.subcategory_id', '=', 'subcategories.id') ->where('subcategories.category_id', $category->id) ->where('listings.city', $location) ->where('listings.approved', true) ->exists(); $hasBusinesses = DB::table('business_profiles') ->where('business_category', $category->id) ->where('city', $location) ->where('approved', true) ->exists(); if ($hasListings || $hasBusinesses) { $metaUpdatedAt = $category->locationMeta() ->whereJsonContains('locations', $location) ->max('updated_at'); $mainUpdatedAt = $category->updated_at; $recentDate = max($metaUpdatedAt ?? '1970-01-01', $mainUpdatedAt ?? '1970-01-01'); $csvData[] = [ route('pages.category-or-subcategory.show', [ 'location' => $encodedLocation, 'slug' => $category->slug ]), $recentDate, 'weekly', '0.8', 'categories' ]; } } foreach ($subcategories as $subcategory) { $hasListings = DB::table('listings') ->where('subcategory_id', $subcategory->id) ->where('city', $location) ->where('approved', true) ->exists(); $hasBusinesses = DB::table('business_profiles') ->where('business_category', $subcategory->id) ->where('city', $location) ->where('approved', true) ->exists(); if ($hasListings || $hasBusinesses) { $metaUpdatedAt = $subcategory->locationMetas() ->where('slug', $encodedLocation) ->max('updated_at'); $mainUpdatedAt = $subcategory->updated_at; $recentDate = max($metaUpdatedAt ?? '1970-01-01', $mainUpdatedAt ?? '1970-01-01'); $csvData[] = [ route('pages.category-or-subcategory.show', [ 'location' => $encodedLocation, 'slug' => $subcategory->slug ]), $recentDate, 'weekly', '0.8', 'subcategories' ]; } } } // India-wide categories (only if they have ANY content) foreach ($categories as $category) { $hasListings = DB::table('listings') ->join('subcategories', 'listings.subcategory_id', '=', 'subcategories.id') ->where('subcategories.category_id', $category->id) ->where('listings.approved', true) ->exists(); $hasBusinesses = DB::table('business_profiles') ->where('business_category', $category->id) ->where('approved', true) ->exists(); if ($hasListings || $hasBusinesses) { $csvData[] = [ route('pages.category-or-subcategory.show', [ 'location' => 'india', 'slug' => $category->slug ]), $category->updated_at ?? now()->toDateTimeString(), 'weekly', '0.8', 'categories' ]; } } // India-wide subcategories (only if they have ANY content) foreach ($subcategories as $subcategory) { $hasListings = DB::table('listings') ->where('subcategory_id', $subcategory->id) ->where('approved', true) ->exists(); $hasBusinesses = DB::table('business_profiles') ->where('business_category', $subcategory->id) ->where('approved', true) ->exists(); if ($hasListings || $hasBusinesses) { $csvData[] = [ route('pages.category-or-subcategory.show', [ 'location' => 'india', 'slug' => $subcategory->slug ]), $subcategory->updated_at ?? now()->toDateTimeString(), 'weekly', '0.8', 'subcategories' ]; } } // ========================================== // LISTINGS - ALL approved listings (from any city) // ========================================== $listings = Listing::where('approved', true)->get(); foreach ($listings as $listing) { if (preg_match('/-AD[0-9]+$/', $listing->slug)) { $csvData[] = [ route('pages.listing.show', [ 'location' => Str::slug($listing->city ?? 'unknown'), 'listing' => $listing->slug ]), $listing->updated_at ? $listing->updated_at->toDateTimeString() : now()->toDateTimeString(), 'weekly', '0.7', 'listings' ]; } } // ========================================== // BUSINESS PROFILES - ALL approved businesses (from any city) // ========================================== $businessProfiles = BusinessProfile::where('approved', true) ->where(function ($query) { $query->whereHas('listings', fn ($items) => $items->where('approved', true)) ->orWhereHas('deals', fn ($items) => $items->where('approved', true)->where('status', 'active')) ->orWhereHas('products', fn ($items) => $items->where('approved', true)->where('status', 'active')); }) ->get(); foreach ($businessProfiles as $profile) { $csvData[] = [ route('pages.business.show', [ 'location' => Str::slug($profile->city ?? 'unknown'), 'business' => $profile->slug ]), $profile->updated_at ? $profile->updated_at->toDateTimeString() : now()->toDateTimeString(), 'weekly', '0.8', 'business_profiles' ]; } // ========================================== // BUSINESS LISTINGS - ALL from approved businesses // ========================================== foreach ($businessProfiles as $profile) { $businessListings = Listing::where('business_profile_id', $profile->id) ->where('approved', true) ->get(); foreach ($businessListings as $listing) { if (preg_match('/-AD[0-9]+$/', $listing->slug)) { $csvData[] = [ route('pages.business.listing.show', [ 'location' => Str::slug($profile->city ?? 'unknown'), 'business' => $profile->slug, 'listing' => $listing->slug ]), $listing->updated_at ? $listing->updated_at->toDateTimeString() : now()->toDateTimeString(), 'weekly', '0.7', 'business_listings' ]; } } } // ========================================== // DEALS - ALL approved deals (via their businesses) // ========================================== $deals = \App\Deal::where('approved', true)->get(); foreach ($deals as $deal) { if ($deal->businessProfile) { $csvData[] = [ route('pages.business.deal.show', [ 'location' => Str::slug($deal->businessProfile->city ?? 'unknown'), 'business' => $deal->businessProfile->slug, 'deal' => $deal->slug ]), $deal->updated_at ? $deal->updated_at->toDateTimeString() : now()->toDateTimeString(), 'weekly', '0.7', 'deals' ]; } } // ========================================== // PRODUCTS - ALL approved products (via their businesses) // ========================================== $products = \App\Product::where('approved', true)->get(); foreach ($products as $product) { if ($product->businessProfile) { $csvData[] = [ route('pages.business.product.show', [ 'location' => Str::slug($product->businessProfile->city ?? 'unknown'), 'business' => $product->businessProfile->slug, 'product' => $product->slug ]), $product->updated_at ? $product->updated_at->toDateTimeString() : now()->toDateTimeString(), 'weekly', '0.7', 'products' ]; } } // ========================================== // BLOG POSTS (with error handling) // ========================================== try { $response = Http::timeout(10)->get('https://public-api.wordpress.com/wp/v2/sites/dealsbarterteam1.wordpress.com/posts'); if ($response->successful()) { $posts = $response->json(); foreach ($posts as $post) { $csvData[] = [ route('posts.show', ['slug' => $post['slug']]), $post['modified'] ?? now()->toDateTimeString(), 'weekly', '0.6', 'blog_posts' ]; } } else { \Log::warning('WordPress API returned non-successful status: ' . $response->status()); $csvData[] = ['# Blog posts skipped - API returned status: ' . $response->status(), '', '', '', '']; } } catch (\Exception $e) { // Log the error but don't fail the entire sitemap generation \Log::error('Failed to fetch WordPress blog posts: ' . $e->getMessage()); $csvData[] = ['# Blog posts skipped - API error: ' . $e->getMessage(), '', '', '', '']; } // ========================================== // LOCATION INDEXES - For all discovered locations // ========================================== foreach ($locations as $location) { $slugLocation = Str::slug($location); $indexTypes = [ 'listings' => DB::table('listings')->where('city', $location)->where('approved', true)->where('paused', false), 'businesses' => DB::table('business_profiles')->where('city', $location)->where('approved', true), 'deals' => DB::table('deals')->join('business_profiles', 'deals.business_profile_id', '=', 'business_profiles.id')->where('business_profiles.city', $location)->where('business_profiles.approved', true)->where('deals.approved', true), 'products' => DB::table('products')->join('business_profiles', 'products.business_profile_id', '=', 'business_profiles.id')->where('business_profiles.city', $location)->where('business_profiles.approved', true)->where('products.approved', true)->where('products.status', 'active'), ]; foreach ($indexTypes as $type => $query) { if ($query->exists()) { $csvData[] = [ route('pages.location.' . $type, ['location' => $slugLocation]), now()->toDateTimeString(), 'daily', '0.9', 'location_indexes' ]; } } } $filename = 'dealsbarter-all-sitemaps-' . date('Y-m-d') . '.csv'; $handle = fopen('php://temp', 'r+'); foreach ($csvData as $row) { fputcsv($handle, $row); } rewind($handle); $csv = stream_get_contents($handle); fclose($handle); return response($csv, 200) ->header('Content-Type', 'text/csv') ->header('Content-Disposition', 'attachment; filename="' . $filename . '"') ->header('Cache-Control', 'no-cache, no-store, must-revalidate') ->header('Pragma', 'no-cache') ->header('Expires', '0'); })->name('generate.sitemaps.csv'); Route::middleware('auth')->group(function () { Route::post('/clear-caches', [CacheController::class, 'clearAllCaches'])->name('clear.all.caches'); }); // Authentication Routes Route::get('/login', function () { return view('auth.login'); })->name('auth.login'); Route::post('/login', [LoginController::class, 'login'])->name('auth.login.submit')->middleware('recaptcha'); Route::get('/register', function () { return view('auth.register'); })->name('auth.register'); Route::post('/register', [RegisterController::class, 'register'])->name('auth.register.submit')->middleware('recaptcha');; Route::post('/check-referral-code', [RegisterController::class, 'checkReferralCode']); Route::middleware(['auth'])->group(function () { Route::get('/business-register', [BusinessProfileController::class, 'register'])->name('business.register'); Route::post('/business-register/store', [BusinessProfileController::class, 'storeBusiness'])->name('business.store'); Route::post('/business/store', [BusinessProfileController::class, 'storeGallery'])->name('business.storegallery'); Route::post('/business/delete-image', [BusinessProfileController::class, 'deleteImage'])->name('business.deleteImage'); }); Route::get('/subcategory/{subcategory}/business-fields', [SubcategoryController::class, 'getBusinessFields']); Route::get('email/verify/{id}/{hash}', [BusinessProfileController::class, 'verifyEmail'])->name('verification.verify'); Route::get('/business-registered', [BusinessProfileController::class, 'showRegistered'])->name('business.registered'); Route::get('/logout', [AuthUserController::class, 'logout'])->name('logout'); Route::get('login/google', [GoogleAuthController::class, 'redirectToGoogle'])->name('google.redirect'); Route::get('/callback/google', [GoogleAuthController::class, 'handleCallback'])->name('google.callback'); // Password Reset Routes Route::get('password/request', [ForgotPasswordController::class, 'showLinkRequestForm'])->name('password.request'); Route::post('password/email', [ForgotPasswordController::class, 'sendResetLinkEmail'])->name('password.email'); Route::get('password/reset/{token}/{email}', [ResetPasswordController::class, 'showResetForm'])->name('password.reset'); Route::post('password/reset', [ResetPasswordController::class, 'reset'])->name('password.update'); // Activation and Success Routes Route::get('/activate/{token}', [ActivationController::class, 'activate']) ->name('pages.activate'); Route::get('/activation-success', function () { return view('auth.activation-success'); })->name('auth.activation-success'); Route::get('/activation-failure', function () { return view('auth.activation-failure'); })->name('auth.activation-failure'); Route::get('/resend-activation', [ResendActivationController::class, 'showResendForm']) ->name('resend-activation'); Route::post('/resend-activation', [ResendActivationController::class, 'resend']) ->name('resend-activation.send'); Route::get('/registration-success', [RegisterController::class, 'registrationSuccess']) ->name('auth.registration-success'); // Static Pages and Other Routes Route::get('/', [HomeController::class, 'index2'])->name('pages.home'); Route::get('/about-us', [PageController::class, 'aboutUs'])->name('pages.about'); Route::get('/contact-us', [ContactController::class, 'index'])->name('pages.contact'); Route::post('/contact', [ContactController::class, 'submitForm'])->name('contact.submit'); Route::get('/pricing', [PricingController::class, 'index'])->name('pages.pricing'); Route::get('/faq', function () { return view('pages.faq'); })->name('pages.faq'); Route::get('/terms-conditions', function () { return view('pages.terms'); })->name('pages.terms'); Route::get('/privacy-policy', function () { return view('pages.privacy'); })->name('pages.privacy'); Route::get('/refund-policy', function () { return view('pages.refund-policy'); })->name('pages.refund-policy'); Route::get('/thankyou', [BusinessProfileController::class, 'showThanksPage'])->name('businessprofile.thankyou'); Route::get('/user/{id}', [WebUserController::class, 'publicProfile'])->name('user.publicProfile'); // Business Profile Routes // Route::get('/business-profile/{business_id}', [BusinessProfileController::class, 'show'])->name('view.business.profile'); Route::get('/businesses', [BusinessProfileController::class, 'index'])->name('businesses.index'); Route::get('/business/success', function () { return view('pages.business-success');})->name('business.success'); Route::get('/business/{slug}', [BusinessProfileController::class, 'show'])->name('business.show'); Route::get('/activate-business-profile', [BusinessProfileController::class, 'activateBusinessProfile'])->name('activate.business.profile'); Route::get('/list-business', [BusinessProfileController::class, 'showPage'])->name('list.business.profile')->middleware('auth.register'); Route::get('/activate-business', [DashboardController::class, 'activateBusiness'])->name('activate.business'); // Listing and Location Routes Route::get('/post-ad', [StepFormController::class, 'showLandingPage'])->name('pages.postad'); Route::middleware(['auth'])->group(function() { Route::get('/create-listing', [StepFormController::class, 'showListingForm'])->name('create.listing'); Route::get('/create-deal', [StepFormController::class, 'showDealForm'])->name('create.deal'); Route::get('/create-product', [StepFormController::class, 'showProductForm'])->name('create.product'); Route::post('/store-listing', [StepFormController::class, 'storeListing'])->name('store.listing'); Route::post('/store-deal', [StepFormController::class, 'storeDeal'])->name('store.deal'); Route::post('/store-product', [StepFormController::class, 'storeProduct'])->name('store.product'); }); // POST store-* handlers are registered inside the auth-middleware group above // (see lines ~385-387) and carry the canonical route names. Route::get('/get-subcategories/{id}', [ListingController::class, 'getSubcategories']); Route::middleware(['auth'])->group(function() { Route::post('/listing/{listing}/express-interest', [ListingController::class, 'expressInterest'])->name('listings.express-interest'); Route::get('/listing/{listing}/check-interest', [ListingController::class, 'checkInterest'])->name('listing.checkInterest'); Route::post('/interests/{interest}/respond', [ListingController::class, 'respondToInterest'])->name('interests.respond'); Route::post('/listings/{listing}/report', [ReportController::class, 'reportListing'])->name('listings.report'); Route::get('/listings/{listing}/check-report', [ReportController::class, 'checkUserReport'])->name('listing.checkReport'); }); // Search Routes Route::get('/search', [SearchController::class, 'search'])->name('pages.search'); Route::get('/search/autocomplete', [SearchController::class, 'autocomplete'])->name('search.autocomplete'); Route::get('/search/loadMore', [SearchController::class, 'loadMoreResults'])->name('search.loadMore'); Route::post('/search/filter', [SearchController::class, 'filter'])->name('search.filter'); Route::get('/deals', [SearchController::class, 'dealsPage'])->name('pages.deals'); Route::get('/products', [SearchController::class, 'productsPage'])->name('pages.products'); Route::get('/business-listings', [BusinessProfileController::class, 'index'])->name('pages.business-listings'); // Lead Routes Route::post('/leads', [LeadController::class, 'store'])->name('leads.store'); // Blog Routes Route::get('/blog', [PostController::class, 'index'])->name('blog'); Route::get('/blog/{slug}', [PostController::class, 'show'])->name('posts.show'); // Newsletter Routes Route::post('/newsletter/subscribe', [NewsletterController::class, 'subscribe'])->name('newsletter.subscribe'); // My Account and Dashboard Routes Route::get('/my-account/', function () {return view('pages.myaccount');})->middleware('auth')->name('pages.account'); Route::get('/my-account/dashboard', [DashboardController::class, 'index'])->middleware('auth')->name('myaccount.dashboard'); Route::get('/my-account/wallet/', [DashboardController::class, 'wallet'])->middleware('auth')->name('myaccount.user.wallet'); Route::get('/my-account/wallet/transactions', [App\Http\Controllers\WalletController::class, 'transactions'])->name('myaccount.wallet.transactions')->middleware('auth'); Route::get('/my-account/wallet/settings', [App\Http\Controllers\WalletController::class, 'settings'])->name('myaccount.wallet.settings')->middleware('auth'); Route::post('/my-account/wallet/send-points', [App\Http\Controllers\WalletController::class, 'sendPoints'])->middleware('auth')->name('wallet.send_points'); Route::post('/api/share-reward', [App\Http\Controllers\WalletController::class, 'logShare'])->middleware('auth')->name('api.share.reward'); Route::get('/my-account/my-orders', [OrderController::class, 'index'])->name('myorders.index')->middleware('auth'); Route::middleware(['auth', 'admin'])->group(function () { Route::get('/my-account/leads', [ContactController::class, 'userLeads'])->name('user.leads.index'); Route::put('/my-account/leads/{id}/mark-read', [ContactController::class, 'markAsRead'])->name('user.leads.mark-read'); }); Route::middleware(['auth', 'business'])->group(function () { Route::get('/my-account/business-manage-coupons', [BusinessController::class, 'listings']) ->name('business.listings'); Route::post('/my-account/business/coupon/{orderItem}/toggle-claim', [BusinessController::class, 'toggleCouponClaim']) ->name('business.coupon.toggle_claim'); }); Route::middleware(['auth'])->prefix('/my-account/referrals')->group(function () { Route::get('/', [DashboardController::class, 'referrals'])->name('myaccount.referrals'); }); Route::middleware(['auth'])->group(function () { Route::get('/invite', [ReferralController::class, 'index'])->name('referral.invite'); }); Route::middleware('auth')->group(function () { Route::get('/temp/add-coins', function () { $user = Auth::user(); $user->addPoints(20000, 'Temporary +20000 coins'); return "Added 20000 coins to user {$user->name}. Current balance: {$user->points}"; }); Route::get('/temp/remove-coins', function () { $user = Auth::user(); $user->addPoints(-200, 'Temporary -200 coins'); return "Removed 200 coins from user {$user->name}. Current balance: {$user->points}"; }); }); // Leads Manage Route::middleware(['auth', 'admin'])->prefix('my-account/manage-leads')->group(function () { Route::get('/', [ContactController::class, 'adminIndex'])->name('admin.leads.index'); Route::put('/{id}/mark-read/{type?}', [ContactController::class, 'markAsRead'])->name('admin.leads.mark-read'); Route::delete('/{id}/{type?}', [ContactController::class, 'destroy'])->name('admin.leads.destroy'); }); Route::middleware(['auth', 'admin'])->prefix('my-account/manage-categories')->group(function () { // Category Routes Route::get('/', [DashboardController::class, 'manageCategories'])->name('myaccount.managecategories'); Route::get('/new', fn() => view('pages.myaccount-newcategory'))->name('myaccount.newcategory'); Route::post('/save', [CategoryController::class, 'saveCategory'])->name('category.save'); Route::delete('/category/{category}/delete', [CategoryController::class, 'deleteCategory'])->name('category.delete'); Route::get('/edit/{id}', [CategoryController::class, 'editCategory'])->name('myaccount.editcategory'); Route::put('/update/{id}', [CategoryController::class, 'updateCategory'])->name('categories.update'); Route::put('/{category}/location/update', [CategoryController::class, 'updateLocationCategory'])->name('category.location.update'); // Subcategory Routes Route::get('/subcategory/new', fn() => view('pages.myaccount-newsubcategory'))->name('myaccount.newsubcategory'); Route::get('/{category}/subcategory/new', [SubcategoryController::class, 'addSubcategory'])->name('subcategory.add'); Route::post('/subcategory/save', [SubcategoryController::class, 'saveSubcategory'])->name('subcategory.save'); Route::get('/{category}/subcategory/{subcategory}/delete', [SubcategoryController::class, 'deleteSubcategory'])->name('subcategory.delete'); Route::get('/{category}/subcategory/{subcategory}/edit', [SubcategoryController::class, 'editSubcategory'])->name('myaccount.editsubcategory'); Route::put('/{category}/{subcategory}/update', [SubcategoryController::class, 'updateSubcategory'])->name('subcategory.update'); Route::put('/{category}/{subcategory}/location/update', [SubcategoryController::class, 'updateLocationSubcategory'])->name('subcategory.location.update'); Route::post('/subcategory/{subcategory}/fields', [SubcategoryController::class, 'storeFields'])->name('subcategory.fields.store'); Route::get('/category/{category}/view', [SubcategoryController::class, 'viewSubcategories'])->name('myaccount.viewsubcategory'); Route::get('/category/subcategory/update/{subcategory_id}/{location}', [SubcategoryController::class, 'getMeta'])->name('locationmeta.get'); Route::get('/display/subcategory-fields/{subcategoryId}', [SubcategoryController::class, 'getListingFields']); }); Route::middleware(['auth', 'admin'])->prefix('my-account/manage-users')->group(function () { Route::get('/', [DashboardController::class, 'manageUsers'])->name('myaccount.manageusers'); Route::get('/search', [DashboardController::class, 'searchManageUser'])->name('user.search'); Route::post('/user/{id}/block-or-unblock/{action}', [DashboardController::class, 'toggleUserBlockStatus'])->name('user.block.unblock'); Route::get('/export-users', [DashboardController::class, 'exportUsers'])->name('export.users'); Route::get('/user/{id}/profile', [DashboardController::class, 'viewUserProfile'])->name('user.profile'); Route::get('/user/{id}/edit', [DashboardController::class, 'editUser'])->name('user.edit'); Route::post('/user/{id}/update', [DashboardController::class, 'updateUser'])->name('user.update'); Route::delete('/user/{id}/delete', [DashboardController::class, 'deleteUser'])->name('user.delete'); Route::get('/admin/user/{id}/listings', [DashboardController::class, 'viewUserListings'])->name('user.listings'); Route::post('/admin/user/{id}/verify', [DashboardController::class, 'verifyUserEmail'])->name('admin.user.verify'); }); Route::middleware(['auth', 'admin'])->prefix('my-account/manage-seo')->group(function () { Route::get('/', [DashboardController::class, 'manageSEO'])->name('myaccount.manageseo'); Route::get('/pages', [DashboardController::class, 'managePagesSEO'])->name('myaccount.managepagesseo'); Route::post('/update', [DashboardController::class, 'updatePagesSEO'])->name('myaccount.manageseo.update'); // Category Meta SEO Route::get('/category-meta', [DashboardController::class, 'manageCategoryDynamicMetaSEO'])->name('myaccount.manageseo.category.dynamicmetaseo'); Route::put('/category-meta', [DashboardController::class, 'manageCategoryDynamicMetaSEO'])->name('myaccount.manageseo.category.dynamicmetaseo.update.location'); Route::get('/category-meta/get-subcategories/{category_id}', [DashboardController::class, 'getSubcategories']); Route::post('/category-meta/update', [DashboardController::class, 'updateManageCategoryDynamicMetaSEO'])->name('myaccount.manageseo.category.dynamicmetaseo.update'); // Listing Meta SEO Route::get('/listings-meta', [DashboardController::class, 'manageListingDynamicMetaSEO'])->name('myaccount.manageseo.listing.dynamicmetaseo'); Route::post('/listings-meta/update', [DashboardController::class, 'updateManageListingDynamicMetaSEO'])->name('myaccount.manageseo.listing.dynamicmetaseo.update'); }); Route::middleware(['auth', 'admin'])->prefix('my-account/redirect-manager')->group(function () { Route::get('/', [DashboardController::class, 'redirectManager'])->name('myaccount.redirectmanager'); Route::post('/update', [DashboardController::class, 'updateRedirectManager'])->name('myaccount.redirectmanager.update'); Route::delete('/delete/{id}', [DashboardController::class, 'deleteRedirect'])->name('myaccount.manageredirects.delete'); }); Route::middleware(['auth'])->prefix('my-account/my-ads')->group(function () { Route::get('/', [DashboardController::class, 'myAds'])->name('myaccount.myads'); Route::get('/listings/{id}/edit', [DashboardController::class, 'editAd'])->name('myaccount.myads.edit'); Route::get('/search', [DashboardController::class, 'searchMyAds'])->name('myads.search'); Route::post('/toggle-pause-resume/{adID}', [DashboardController::class, 'pauseAd'])->name('ad.pauseAd'); Route::get('/edit/{id}', [DashboardController::class, 'editAd'])->name('ad.edit'); Route::put('/update/{id}', [DashboardController::class, 'updateAd'])->name('ad.update'); Route::post('/delete-ad/{adID}', [DashboardController::class, 'deleteAd'])->name('deleteAd'); }); Route::middleware(['auth'])->prefix('my-account/my-business-deals')->group(function () { Route::get('/', [DashboardController::class, 'myDeals'])->name('business.deals'); Route::get('/search', [DashboardController::class, 'searchMyDeals'])->name('business.deals.search'); Route::post('/toggle-pause-resume/{id}', [DashboardController::class, 'pauseDeal'])->name('business.deals.pause'); Route::get('/edit/{id}', [DashboardController::class, 'editDeal'])->name('business.deals.edit'); Route::put('/update/{id}', [DashboardController::class, 'updateDeal'])->name('business.deals.update'); Route::post('/delete/{id}', [DashboardController::class, 'deleteDeal'])->name('business.deals.delete'); }); Route::middleware(['auth'])->prefix('my-account/manage-deals')->group(function () { Route::get('/deals/{id}/edit', [DashboardController::class, 'editDeal'])->name('myaccount.deals.edit'); Route::post('/deals/{id}', [DashboardController::class, 'updateDeal'])->name('myaccount.deals.update'); }); Route::middleware(['auth'])->prefix('my-account/my-business-products')->group(function () { Route::get('/', [DashboardController::class, 'myProducts'])->name('business.products'); Route::get('/search', [DashboardController::class, 'searchMyProducts'])->name('business.products.search'); Route::post('/toggle-pause-resume/{id}', [DashboardController::class, 'pauseProduct'])->name('business.products.pause'); Route::get('/edit/{id}', [DashboardController::class, 'editProduct'])->name('business.products.edit'); Route::put('/update/{id}', [DashboardController::class, 'updateProduct'])->name('business.products.update'); Route::post('/delete/{id}', [DashboardController::class, 'deleteProduct'])->name('business.products.delete'); }); Route::middleware(['auth', 'admin'])->prefix('my-account/manage-ads')->group(function () { Route::get('/', [DashboardController::class, 'manageAds'])->name('myaccount.manageads'); Route::post('/bulk-actions', [DashboardController::class, 'bulkActions'])->name('myaccount.bulkActions'); Route::post('/listing/{id}/change-status/{action}', [DashboardController::class, 'changeListingStatus'])->name('myaccount.changeStatus'); Route::post('/listing/{id}/favourite-status/{action}', [DashboardController::class, 'changeFavouriteListing'])->name('myaccount.changeFavouriteListing'); Route::get('/listings/{id}/edit', [DashboardController::class, 'editListing'])->name('myaccount.listings.edit'); Route::post('/listings/{id}', [DashboardController::class, 'updateListing'])->name('myaccount.listings.update'); Route::get('/delete-listing/{id}', [DashboardController::class, 'deleteListing'])->name('myaccount.deleteListing'); }); Route::delete('/my-account/delete-image/{id}', [DashboardController::class, 'deleteListingImage'])->name('myaccount.delete.image'); Route::delete('/my-account/delete-brochure/{id}', [DashboardController::class, 'deleteBrochure'])->name('myaccount.delete.brochure'); Route::delete('/my-account/delete-video/{id}', [DashboardController::class, 'deleteDealVideo']); Route::delete('/my-account/delete-product-video/{id}', [DashboardController::class, 'deleteProductVideo'])->name('myaccount.deleteProductVideo'); // Image upload routes Route::post('/my-account/upload-image', [DashboardController::class, 'uploadImage'])->name('myaccount.upload.image'); Route::delete('/my-account/remove-uploaded-image', [DashboardController::class, 'removeUploadedImage'])->name('myaccount.remove.uploaded.image'); Route::middleware(['auth', 'admin'])->prefix('my-account')->group(function () { Route::get('/manage-businesses', [DashboardController::class, 'manageBusinesses'])->name('myaccount.managebusinesses'); Route::post('/business/{id}/featured-status/{action}', [DashboardController::class, 'changeFavouriteBusiness'])->name('myaccount.changeFavouriteBusiness'); Route::post('/manage-businesses/bulk-actions', [DashboardController::class, 'bulkBusinessActions'])->name('myaccount.bulkBusinessActions'); Route::get('/export-businesses', [DashboardController::class, 'exportBusinesses'])->name('export.businesses'); Route::get('/business/{business}/view', [DashboardController::class, 'viewBusiness'])->name('myaccount.viewBusiness'); Route::post('/business/{business}/change-status', [DashboardController::class, 'changeStatus'])->name('myaccount.changeBusinessStatus'); Route::get('/manage-businesses/{business}/edit', [DashboardController::class, 'editBusiness'])->name('myaccount.editBusiness'); Route::post('/business/{business}/update', [DashboardController::class, 'updateBusiness'])->name('myaccount.updateBusiness'); Route::post('/business/delete-business/{business}', [DashboardController::class, 'deleteBusiness'])->name('myaccount.deleteBusiness'); Route::post('/businesses/bulk-change-status', [DashboardController::class, 'bulkChangeStatus'])->name('myaccount.bulkChangeBusinessStatus'); Route::post('/businesses/bulk-delete', [DashboardController::class, 'bulkDelete'])->name('myaccount.bulkDeleteBusinesses'); }); Route::middleware(['auth']) ->prefix('my-account/related-categories') ->name('admin.related-categories.') ->group(function () { Route::get('/', [DashboardController::class, 'manageRelatedCategories']) ->name('index'); Route::post('/', [DashboardController::class, 'addRelatedCategory']) ->name('store'); Route::delete('/{categoryId}', [DashboardController::class, 'removeRelatedCategory']) ->name('destroy'); }); Route::middleware(['auth', 'admin']) ->prefix('my-account/manage-categories') ->name('admin.subcategories.') ->group(function () { Route::get('subcategory/{subcategory}/related', [DashboardController::class, 'manageSubcategoryRelated'] )->name('related'); Route::post('subcategory/{subcategory}/related', [DashboardController::class, 'storeSubcategoryRelated'] )->name('related.store'); Route::delete('subcategory/{subcategory}/related/{relatedSubcategory}', [DashboardController::class, 'destroySubcategoryRelated'] )->name('related.destroy'); }); Route::middleware(['auth', 'admin'])->prefix('my-account/manage-deals')->group(function () { Route::get('/', [DashboardController::class, 'manageDeals'])->name('myaccount.managedeals'); Route::post('/deal/{id}/change-status/{action}', [DashboardController::class, 'changeDealStatus'])->name('myaccount.changeDealStatus'); Route::post('/deal/{id}/toggle-featured/{action}', [DashboardController::class, 'toggleDealFeatured'])->name('myaccount.toggleDealFeatured'); Route::post('/delete-deal/{id}', [DashboardController::class, 'deleteDeal'])->name('myaccount.deleteDeal'); Route::post('/toggle-pause-resume/{dealId}', [DashboardController::class, 'pauseDeal'])->name('deal.pauseDeal'); }); Route::middleware(['auth', 'admin'])->prefix('my-account/manage-products')->group(function () { Route::get('/', [DashboardController::class, 'manageProducts'])->name('myaccount.manageproducts'); Route::post('/product/{id}/change-status/{action}', [DashboardController::class, 'changeProductStatus'])->name('myaccount.changeProductStatus'); Route::post('/product/{id}/toggle-featured/{action}', [DashboardController::class, 'toggleProductFeatured'])->name('myaccount.toggleProductFeatured'); Route::get('/products/{id}/edit', [DashboardController::class, 'editProduct'])->name('myaccount.products.edit'); Route::post('/products/{id}', [DashboardController::class, 'updateProduct'])->name('myaccount.products.update'); Route::post('/delete-product/{id}', [DashboardController::class, 'deleteProduct'])->name('myaccount.deleteProduct'); Route::post('/toggle-pause-resume/{productId}', [DashboardController::class, 'pauseProduct'])->name('product.pauseProduct'); }); Route::middleware(['auth', 'admin']) ->prefix('my-account/manage-subcategory-terms') ->group(function () { Route::get('/', [BusinessTermsController::class, 'index']) ->name('myaccount.subcategory.terms.list'); Route::get('/{subcategory}/edit', [BusinessTermsController::class, 'edit']) ->name('myaccount.subcategory.terms.edit'); Route::post('/{subcategory}', [BusinessTermsController::class, 'update']) ->name('myaccount.subcategory.terms.update'); Route::delete('/{subcategory}', [BusinessTermsController::class, 'clearTerms']) ->name('myaccount.subcategory.terms.clear'); }); Route::middleware(['auth', 'admin'])->prefix('my-account/manage-offers')->name('admin.predefined-deals.')->group(function () { Route::get('/', [App\Http\Controllers\Admin\PredefinedDealsController::class, 'index'])->name('index'); Route::get('/create', [App\Http\Controllers\Admin\PredefinedDealsController::class, 'create'])->name('create'); Route::post('/', [App\Http\Controllers\Admin\PredefinedDealsController::class, 'store'])->name('store'); Route::get('/{predefinedDeal}/edit', [App\Http\Controllers\Admin\PredefinedDealsController::class, 'edit'])->name('edit'); Route::put('/{predefinedDeal}', [App\Http\Controllers\Admin\PredefinedDealsController::class, 'update'])->name('update'); Route::delete('/{predefinedDeal}', [App\Http\Controllers\Admin\PredefinedDealsController::class, 'destroy'])->name('destroy'); }); Route::middleware(['auth', 'admin'])->prefix('my-account/manage-blog')->group(function () { Route::get('/', [DashboardController::class, 'manageBlogPosts'])->name('myaccount.manageblog'); }); Route::get('/my-account/my-profile/', [DashboardController::class, 'viewProfile'])->middleware('auth')->name('myaccount.myprofile'); Route::put('/my-account/my-profile/update', [DashboardController::class, 'updateProfile'])->middleware('auth')->name('myprofile.update'); Route::get('/my-account/business-profile/', [DashboardController::class, 'viewBusinessProfile'])->middleware('auth')->name('myaccount.businessprofile'); Route::put('/my-account/business-profile/update', [DashboardController::class, 'updateBusinessProfile'])->middleware('auth')->name('businessprofile.update'); Route::get('/my-account/my-account/inbox/', [DashboardController::class, 'inbox'])->middleware('auth')->name('myaccount.inbox'); Route::get('/my-account/settings', [SettingsController::class, 'showSettings'])->middleware('auth')->name('myaccount.settings'); Route::put('/my-account/settings', [SettingsController::class, 'updateSettings'])->middleware('auth')->name('myaccount.settings.update'); Route::get('/my-account/interests', [DashboardController::class, 'getInterests'])->name('user.interests'); Route::middleware(['auth', 'admin'])->prefix('my-account')->group(function () { Route::get('/manage-reports', [DashboardController::class, 'reportLisings'])->name('admin.reports.index'); Route::get('/manage-reports/{report}', [DashboardController::class, 'showListingReport'])->name('admin.reports.show'); Route::post('/manage-reports/{report}/update-status', [DashboardController::class, 'updateListingReportStatus'])->name('admin.reports.updateStatus'); Route::delete('/manage-reports/{report}', [DashboardController::class, 'destroyListingReportStatus'])->name('admin.reports.destroy'); Route::post('/manage-reports/bulk-action', [DashboardController::class, 'bulkActionReportListing'])->name('admin.reports.bulkAction'); }); Route::middleware('auth')->group(function () { Route::post('/favorites/add', [FavoritesController::class, 'addFavorite'])->name('favorites.add'); Route::post('/favorites/remove', [FavoritesController::class, 'removeFavorite'])->name('favorites.remove'); Route::post('/favorites/toggle', [FavoritesController::class, 'toggleFavorite'])->name('favorites.toggle'); Route::get('/favorites/check/{listing}', [FavoritesController::class, 'checkFavoriteStatus'])->name('favorites.check'); Route::get('/favorites/count', [FavoritesController::class, 'getFavoritesCount'])->name('favorites.count'); Route::get('/favorites/list', [FavoritesController::class, 'getFavoritesList'])->name('favorites.list'); Route::post('/favorites/clear-all', [FavoritesController::class, 'clearAllFavorites'])->name('favorites.clearAll'); Route::get('/my-account/favourites', [FavoritesController::class, 'showFavoritesPage'])->name('favorites.page'); }); Route::middleware('auth')->group(function () { Route::post('/deals/claim', [WalletController::class, 'claim'])->name('deals.claim'); }); // Route::middleware('auth')->group(function () { // Route::get('/dealbox', [CartController::class, 'show'])->name('pages.dealbox.show'); // Route::post('/dealbox/add-deal', [CartController::class, 'addDeal'])->name('dealbox.add.deal'); // Route::post('/dealbox/add-product', [CartController::class, 'addProduct'])->name('dealbox.add.product'); // Route::delete('/dealbox/remove', [CartController::class, 'removeFromDealBox'])->name('dealbox.remove'); // Route::post('/dealbox/remove-multiple', [CartController::class, 'removeMultiple'])->name('dealbox.remove.multiple'); // Route::post('/dealbox/clear', [CartController::class, 'clearAll'])->name('dealbox.clear'); // Route::get('/dealbox/export', [CartController::class, 'export'])->name('dealbox.export'); // Route::get('/dealbox/checkout', [CheckoutController::class, 'checkoutDealbox'])->name('pages.dealbox.checkout'); // Route::post('/dealbox/generate-coupons', [CheckoutController::class, 'generateCoupons'])->name('dealbox.generate_coupons'); // Route::post('/dealbox/update-quantity', [CartController::class, 'updateQuantity'])->name('dealbox.update.quantity'); // }); Route::middleware(['auth'])->prefix('dealbox')->name('pages.dealbox.')->group(function () { Route::get('/', [DealBoxController::class, 'show'])->name('show'); // Add items Route::post('/add-deal', [DealBoxController::class, 'addDeal'])->name('add.deal'); Route::post('/add-product', [DealBoxController::class, 'addProduct'])->name('add.product'); // Remove items Route::delete('/remove-item', [DealBoxController::class, 'removeItem'])->name('remove.item'); // Check items Route::get('/check-deal/{dealId}', [DealBoxController::class, 'checkDeal'])->name('check.deal'); Route::get('/check-product/{productId}', [DealBoxController::class, 'checkProduct'])->name('check.product'); // Other actions Route::get('/count', [DealBoxController::class, 'getCount'])->name('count'); Route::patch('/update-quantity', [DealBoxController::class, 'updateQuantity'])->name('update.quantity'); // Add these checkout routes Route::get('/checkout', [DealBoxController::class, 'checkout'])->name('checkout'); Route::post('/process-checkout', [DealBoxController::class, 'processCheckout'])->name('process.checkout'); Route::post('/phonepe/callback', [DealBoxController::class, 'phonePeCallback'])->name('dealbox.phonepe.callback'); Route::get('/phonepe/callback', [DealBoxController::class, 'phonePeCallback']); }); Route::middleware(['auth'])->group(function () { Route::get('/my-dealbox', [DealBoxController::class, 'show'])->name('pages.dealbox.show.my'); }); Route::get('/phonepe/test', [\App\Http\Controllers\PhonePeController::class, 'paymentPage'])->name('phonepe.test'); Route::post('/phonepe/pay', [\App\Http\Controllers\PhonePeController::class, 'pay'])->name('phonepe.pay'); Route::any('/phonepe/callback', [\App\Http\Controllers\PhonePeController::class, 'callback'])->name('phonepe.callback'); // Subscription upgrade Route::post('/subscription/upgrade/process', [SubscriptionController::class, 'upgrade'] )->name('subscription.upgrade.process'); // PhonePe – prepare payment (MUST MATCH controller redirect) Route::get('/subscription/payment/phonepe', [SubscriptionController::class, 'startPhonePePayment'] )->name('subscription.payment.phonepe'); // PhonePe callback Route::get('/subscription/payment/phonepe/callback', [SubscriptionController::class, 'phonePeCallback'] )->name('subscription.payment.phonepe.callback'); Route::get('/favorites/status/{listing}', [FavoritesController::class, 'checkFavoriteStatus'])->name('favorites.status'); Route::middleware(['auth'])->group(function () { Route::get('/business/{id}/claim', [BusinessClaimController::class, 'showClaimForm']) ->name('business.claim'); Route::post('/business/{id}/claim', [BusinessClaimController::class, 'submitClaim']) ->name('business.claim.submit'); }); Route::middleware(['auth'])->group(function () { Route::get('/my-account/claims', [BusinessClaimController::class, 'myClaims']) ->name('myaccount.claims'); Route::get('/my-account/disputes', [BusinessClaimController::class, 'myDisputes']) ->name('myaccount.disputes'); Route::post('/business/{id}/dispute', [BusinessClaimController::class, 'submitDispute']) ->name('business.dispute.submit'); }); Route::get('/business/{id}/dispute', [BusinessClaimController::class, 'showDisputeForm']) ->name('business.dispute'); Route::middleware(['auth', 'admin']) ->prefix('my-account') ->group(function () { Route::get('/manage-claims', [BusinessClaimController::class, 'adminViewClaims']) ->name('myaccount.manageclaims'); Route::get('/claim/{id}', [BusinessClaimController::class, 'adminViewClaim']) ->name('myaccount.viewclaim'); Route::post('/claim/{id}/approve', [BusinessClaimController::class, 'adminApproveClaim']) ->name('myaccount.approveclaim'); Route::post('/claim/{id}/reject', [BusinessClaimController::class, 'adminRejectClaim']) ->name('myaccount.rejectclaim'); Route::get('/manage-disputes', [BusinessClaimController::class, 'adminViewDisputes']) ->name('myaccount.managedisputes'); Route::get('/dispute/{id}', [BusinessClaimController::class, 'adminViewDispute']) ->name('myaccount.viewdispute'); Route::post('/dispute/{id}/resolve', [BusinessClaimController::class, 'adminResolveDispute']) ->name('myaccount.resolvedispute'); Route::post('/dispute/{id}/reject', [BusinessClaimController::class, 'adminRejectDispute']) ->name('myaccount.rejectdispute'); }); Route::group([ 'as' => 'pages.', 'middleware' => ['web', 'set.user.location', 'track.city'] ], function () { Route::get('/{location}/listings', [LocationWiseController::class, 'allListings']) ->name('location.listings'); Route::get('/{location}/businesses', [LocationWiseController::class, 'allBusinesses']) ->name('location.businesses'); Route::get('/{location}/deals', [LocationWiseController::class, 'allDeals']) ->name('location.deals'); Route::get('/{location}/products', [LocationWiseController::class, 'allProducts']) ->name('location.products'); Route::get('/{location}', [LocationWiseController::class, 'show']) ->name('location.show'); Route::get('/{location}/{business}', [BusinessProfileController::class, 'showListings']) ->name('business.show') ->where('business', '[a-z0-9-]+-BD[0-9]{6}'); Route::get('/{location}/{business}/{listing}', [BusinessProfileController::class, 'showBusinessListing']) ->name('business.listing.show') ->where('business', '[a-z0-9-]+-BD[0-9]{6}') ->where('listing', '[a-zA-Z0-9\-]+-AD[0-9]+'); Route::get('/{location}/{business}/{deal}', [DealController::class, 'showDeal']) ->name('business.deal.show') ->where('business', '[a-z0-9-]+-BD[0-9]{6}') ->where('deal', '[a-z0-9-]+-DL[0-9]+'); Route::get('/{location}/{business}/{product}', [ProductController::class, 'showProduct']) ->name('business.product.show') ->where('business', '[a-z0-9-]+-BD[0-9]{6}') ->where('product', '[a-z0-9-]+-PR[0-9]+'); Route::get('/{location}/{listing}', [ListingController::class, 'show']) ->name('listing.show') ->middleware('check.location') ->where('listing', '[a-zA-Z0-9\-]+-AD[0-9]+'); Route::get('/{location}/{slug}', [CategoryPageController::class, 'show']) ->name('category-or-subcategory.show'); Route::get('/{location}/{subcategory}/{listing}', [LocationWiseController::class, 'showListingsByLocationSubcategory']) ->name('location.subcategory.listing.show') ->where('listing', '[a-zA-Z0-9\-]+-AD[a-zA-Z0-9]+'); }); Route::post('/category-enquiry', [CategoryPageController::class, 'storeCategoryEnquiry'])->name('category.enquiry'); Route::get('/ajax/category/{location}/{slug}', [CategoryPageController::class, 'ajaxLoadMore'])->name('category.load-more'); // Additional routes Route::get('/get-location', [LocationController::class, 'getLocation']); Route::get('listings/filter/{type}/{value}', [ListingController::class, 'filter'])->name('listings.filter'); Route::get('/display/subcategory-fields/{subcategoryId}', [SubcategoryController::class, 'getSubcategoryFields']); Route::post('/improve-description', [ListingController::class, 'improveDescription'])->name('improve.description'); Route::prefix('analytics')->middleware(['auth', 'check.admin:admin'])->group(function () { Route::get('/listing-count/by-subcategory-city', [AnalyticsController::class, 'listingCountBySubcategoryAndCity']) ->name('analytics.listing-count.by-subcategory-city'); Route::get('/export-listing-count/by-subcategory-city', [AnalyticsController::class, 'exportListingCountBySubcategoryAndCity']) ->name('analytics.export-listing-count.by-subcategory-city'); Route::get('/business-count/by-subcategory-city', [AnalyticsController::class, 'businessCountBySubcategoryAndCity']) ->name('analytics.business-count.by-subcategory-city'); Route::get('/export-business-count/by-subcategory-city', [AnalyticsController::class, 'exportBusinessCountBySubcategoryAndCity']) ->name('analytics.export-business-count.by-subcategory-city'); }); // routes/web.php Route::get('/test-helpers', function() { $coins = 100; $rupees = dbCoinsToRupees($coins); return [ 'coins' => formatDbCoins($coins), 'rupees' => formatRupees($rupees), 'conversion' => config('dealbox.conversion_rate'), ]; }); Route::get('/test-notifications', function() { if (!auth()->check()) { return 'Please login first'; } $business = \App\BusinessProfile::where('user_id', auth()->id())->first(); if (!$business) { return 'No business profile found'; } $notificationService = new \App\Services\NotificationService(); // Test SMS $sms = $notificationService->sendSMS( $business->mobile, 'Test message from DealsBarter!' ); // Test Email try { Mail::raw('This is a test email from DealsBarter', function($message) use ($business) { $message->to($business->email) ->subject('Test Email'); }); $email = true; } catch (\Exception $e) { $email = false; } return [ 'sms_sent' => $sms, 'email_sent' => $email, 'business' => $business->business_name, 'mobile' => $business->mobile, 'email' => $business->email ]; })->middleware('auth'); Route [logout] not defined. (View: /var/www/dealsbarter2/resources/views/elements/navbar.blade.php) (View: /var/www/dealsbarter2/resources/views/elements/navbar.blade.php) (View: /var/www/dealsbarter2/resources/views/elements/navbar.blade.php) (500 Internal Server Error)

Symfony Exception

Route [logout] not defined. (View: /var/www/dealsbarter2/resources/views/elements/navbar.blade.php) (View: /var/www/dealsbarter2/resources/views/elements/navbar.blade.php) (View: /var/www/dealsbarter2/resources/views/elements/navbar.blade.php)

Exceptions 4

Illuminate\View\ ViewException

  1.     {
  2.         if (! is_null($route = $this->routes->getByName($name))) {
  3.             return $this->toRoute($route, $parameters, $absolute);
  4.         }
  5.         throw new RouteNotFoundException("Route [{$name}] not defined.");
  6.     }
  7.     /**
  8.      * Get the URL for a given route instance.
  9.      *
  1.         // flush out any stray output that might get out before an error occurs or
  2.         // an exception is thrown. This prevents any partial views from leaking.
  3.         try {
  4.             $this->files->getRequire($path, $data);
  5.         } catch (Throwable $e) {
  6.             $this->handleViewException($e, $obLevel);
  7.         }
  8.         return ltrim(ob_get_clean());
  9.     }
  1.         }
  2.         // Once we have the path to the compiled file, we will evaluate the paths with
  3.         // typical PHP just like any other templates. We also keep a stack of views
  4.         // which have been rendered for right exception messages to be generated.
  5.         $results = $this->evaluatePath($this->compiler->getCompiledPath($path), $data);
  6.         array_pop($this->lastCompiled);
  7.         return $results;
  8.     }
  1.      *
  2.      * @return string
  3.      */
  4.     protected function getContents()
  5.     {
  6.         return $this->engine->get($this->path, $this->gatherData());
  7.     }
  8.     /**
  9.      * Get the data bound to the view instance.
  10.      *
  1.         // clear out the sections for any separate views that may be rendered.
  2.         $this->factory->incrementRender();
  3.         $this->factory->callComposer($this);
  4.         $contents = $this->getContents();
  5.         // Once we've finished rendering the view, we'll decrement the render count
  6.         // so that each sections get flushed out next time a view is created and
  7.         // no old sections are staying around in the memory of an environment.
  8.         $this->factory->decrementRender();
  1.      * @throws \Throwable
  2.      */
  3.     public function render(callable $callback = null)
  4.     {
  5.         try {
  6.             $contents = $this->renderContents();
  7.             $response = isset($callback) ? $callback($this, $contents) : null;
  8.             // Once we have the contents of the view, we will flush the sections if we are
  9.             // done rendering all views so that there is nothing left hanging over when
  1.         // If this content implements the "Renderable" interface then we will call the
  2.         // render method on the object so we will avoid any "__toString" exceptions
  3.         // that might be thrown and have their errors obscured by PHP's handling.
  4.         elseif ($content instanceof Renderable) {
  5.             $content = $content->render();
  6.         }
  7.         parent::setContent($content);
  8.         return $this;
  1.      */
  2.     public function __construct($content = '', $status = 200, array $headers = [])
  3.     {
  4.         $this->headers = new ResponseHeaderBag($headers);
  5.         $this->setContent($content);
  6.         $this->setStatusCode($status);
  7.         $this->setProtocolVersion('1.0');
  8.     }
  9.     /**
  1.      * @param  array  $headers
  2.      * @return \Illuminate\Http\Response
  3.      */
  4.     public function make($content = '', $status = 200, array $headers = [])
  5.     {
  6.         return new Response($content, $status, $headers);
  7.     }
  8.     /**
  9.      * Create a new "no content" response.
  10.      *
  1.     {
  2.         if (is_array($view)) {
  3.             return $this->make($this->view->first($view, $data), $status, $headers);
  4.         }
  5.         return $this->make($this->view->make($view, $data), $status, $headers);
  6.     }
  7.     /**
  8.      * Create a new JSON response instance.
  9.      *
ResponseFactory->view() in /var/www/dealsbarter2/app/Exceptions/Handler.php (line 55)
  1.      * @throws \Throwable
  2.      */
  3.     public function render($request, Throwable $exception)
  4.     {
  5.         if ($exception instanceof NotFoundHttpException) {
  6.             return response()->view('pages.404', compact('exception'), 404);
  7.         }
  8.         return parent::render($request, $exception);
  9.     }
  10. }
  1.         $handler = $this->container->make(ExceptionHandler::class);
  2.         $handler->report($e);
  3.         $response = $handler->render($passable, $e);
  4.         if (is_object($response) && method_exists($response, 'withException')) {
  5.             $response->withException($e);
  6.         }
  1.     {
  2.         return function ($passable) use ($destination) {
  3.             try {
  4.                 return $destination($passable);
  5.             } catch (Throwable $e) {
  6.                 return $this->handleException($passable, $e);
  7.             }
  8.         };
  9.     }
  10.     /**
Pipeline->Illuminate\Pipeline\{closure}() in /var/www/dealsbarter2/app/Http/Middleware/RedirectIfMatched.php (line 29)
  1.     if ($redirect) {
  2.         return response()->view('pages.redirect', ['newUrl' => $redirect->new_url]);
  3.     }
  4.     return $next($request);
  5. }
  6. }
  1.                         // since the object we're given was already a fully instantiated object.
  2.                         $parameters = [$passable, $stack];
  3.                     }
  4.                     $carry = method_exists($pipe, $this->method)
  5.                                     ? $pipe->{$this->method}(...$parameters)
  6.                                     : $pipe(...$parameters);
  7.                     return $this->handleCarry($carry);
  8.                 } catch (Throwable $e) {
  9.                     return $this->handleException($passable, $e);
  1.      */
  2.     public function handle($request, Closure $next)
  3.     {
  4.         $this->clean($request);
  5.         return $next($request);
  6.     }
  7.     /**
  8.      * Clean the request's data.
  9.      *
  1.             if ($callback($request)) {
  2.                 return $next($request);
  3.             }
  4.         }
  5.         return parent::handle($request, $next);
  6.     }
  7.     /**
  8.      * Transform the given value.
  9.      *
  1.                         // since the object we're given was already a fully instantiated object.
  2.                         $parameters = [$passable, $stack];
  3.                     }
  4.                     $carry = method_exists($pipe, $this->method)
  5.                                     ? $pipe->{$this->method}(...$parameters)
  6.                                     : $pipe(...$parameters);
  7.                     return $this->handleCarry($carry);
  8.                 } catch (Throwable $e) {
  9.                     return $this->handleException($passable, $e);
  1.      */
  2.     public function handle($request, Closure $next)
  3.     {
  4.         $this->clean($request);
  5.         return $next($request);
  6.     }
  7.     /**
  8.      * Clean the request's data.
  9.      *
  1.             if ($callback($request)) {
  2.                 return $next($request);
  3.             }
  4.         }
  5.         return parent::handle($request, $next);
  6.     }
  7.     /**
  8.      * Transform the given value.
  9.      *
  1.                         // since the object we're given was already a fully instantiated object.
  2.                         $parameters = [$passable, $stack];
  3.                     }
  4.                     $carry = method_exists($pipe, $this->method)
  5.                                     ? $pipe->{$this->method}(...$parameters)
  6.                                     : $pipe(...$parameters);
  7.                     return $this->handleCarry($carry);
  8.                 } catch (Throwable $e) {
  9.                     return $this->handleException($passable, $e);
  1.         if ($max > 0 && $request->server('CONTENT_LENGTH') > $max) {
  2.             throw new PostTooLargeException;
  3.         }
  4.         return $next($request);
  5.     }
  6.     /**
  7.      * Determine the server 'post_max_size' as bytes.
  8.      *
  1.                         // since the object we're given was already a fully instantiated object.
  2.                         $parameters = [$passable, $stack];
  3.                     }
  4.                     $carry = method_exists($pipe, $this->method)
  5.                                     ? $pipe->{$this->method}(...$parameters)
  6.                                     : $pipe(...$parameters);
  7.                     return $this->handleCarry($carry);
  8.                 } catch (Throwable $e) {
  9.                     return $this->handleException($passable, $e);
  1.                 null,
  2.                 $this->getHeaders($data)
  3.             );
  4.         }
  5.         return $next($request);
  6.     }
  7.     /**
  8.      * Determine if the incoming request has a maintenance mode bypass cookie.
  9.      *
  1.                         // since the object we're given was already a fully instantiated object.
  2.                         $parameters = [$passable, $stack];
  3.                     }
  4.                     $carry = method_exists($pipe, $this->method)
  5.                                     ? $pipe->{$this->method}(...$parameters)
  6.                                     : $pipe(...$parameters);
  7.                     return $this->handleCarry($carry);
  8.                 } catch (Throwable $e) {
  9.                     return $this->handleException($passable, $e);
  1.      */
  2.     public function handle($request, Closure $next)
  3.     {
  4.         // Check if we're dealing with CORS and if we should handle it
  5.         if (! $this->shouldRun($request)) {
  6.             return $next($request);
  7.         }
  8.         // For Preflight, return the Preflight response
  9.         if ($this->cors->isPreflightRequest($request)) {
  10.             $response = $this->cors->handlePreflightRequest($request);
  1.                         // since the object we're given was already a fully instantiated object.
  2.                         $parameters = [$passable, $stack];
  3.                     }
  4.                     $carry = method_exists($pipe, $this->method)
  5.                                     ? $pipe->{$this->method}(...$parameters)
  6.                                     : $pipe(...$parameters);
  7.                     return $this->handleCarry($carry);
  8.                 } catch (Throwable $e) {
  9.                     return $this->handleException($passable, $e);
  1.     {
  2.         $request::setTrustedProxies([], $this->getTrustedHeaderNames());
  3.         $this->setTrustedProxyIpAddresses($request);
  4.         return $next($request);
  5.     }
  6.     /**
  7.      * Sets the trusted proxies on the request.
  8.      *
  1.                         // since the object we're given was already a fully instantiated object.
  2.                         $parameters = [$passable, $stack];
  3.                     }
  4.                     $carry = method_exists($pipe, $this->method)
  5.                                     ? $pipe->{$this->method}(...$parameters)
  6.                                     : $pipe(...$parameters);
  7.                     return $this->handleCarry($carry);
  8.                 } catch (Throwable $e) {
  9.                     return $this->handleException($passable, $e);
  1.     {
  2.         $pipeline = array_reduce(
  3.             array_reverse($this->pipes()), $this->carry(), $this->prepareDestination($destination)
  4.         );
  5.         return $pipeline($this->passable);
  6.     }
  7.     /**
  8.      * Run the pipeline and return the result.
  9.      *
  1.         $this->bootstrap();
  2.         return (new Pipeline($this->app))
  3.                     ->send($request)
  4.                     ->through($this->app->shouldSkipMiddleware() ? [] : $this->middleware)
  5.                     ->then($this->dispatchToRouter());
  6.     }
  7.     /**
  8.      * Bootstrap the application for HTTP requests.
  9.      *
  1.     public function handle($request)
  2.     {
  3.         try {
  4.             $request->enableHttpMethodParameterOverride();
  5.             $response = $this->sendRequestThroughRouter($request);
  6.         } catch (Throwable $e) {
  7.             $this->reportException($e);
  8.             $response = $this->renderException($request, $e);
  9.         }
Kernel->handle() in /var/www/dealsbarter2/public/index.php (line 51)
  1. $app = require_once __DIR__.'/../bootstrap/app.php';
  2. $kernel = $app->make(Kernel::class);
  3. $response = $kernel->handle(
  4.     $request = Request::capture()
  5. )->send();
  6. $kernel->terminate($request, $response);

Illuminate\View\ ViewException

Route [logout] not defined. (View: /var/www/dealsbarter2/resources/views/elements/navbar.blade.php) (View: /var/www/dealsbarter2/resources/views/elements/navbar.blade.php)

  1.     {
  2.         if (! is_null($route = $this->routes->getByName($name))) {
  3.             return $this->toRoute($route, $parameters, $absolute);
  4.         }
  5.         throw new RouteNotFoundException("Route [{$name}] not defined.");
  6.     }
  7.     /**
  8.      * Get the URL for a given route instance.
  9.      *
  1.         // flush out any stray output that might get out before an error occurs or
  2.         // an exception is thrown. This prevents any partial views from leaking.
  3.         try {
  4.             $this->files->getRequire($path, $data);
  5.         } catch (Throwable $e) {
  6.             $this->handleViewException($e, $obLevel);
  7.         }
  8.         return ltrim(ob_get_clean());
  9.     }
  1.         }
  2.         // Once we have the path to the compiled file, we will evaluate the paths with
  3.         // typical PHP just like any other templates. We also keep a stack of views
  4.         // which have been rendered for right exception messages to be generated.
  5.         $results = $this->evaluatePath($this->compiler->getCompiledPath($path), $data);
  6.         array_pop($this->lastCompiled);
  7.         return $results;
  8.     }
  1.      *
  2.      * @return string
  3.      */
  4.     protected function getContents()
  5.     {
  6.         return $this->engine->get($this->path, $this->gatherData());
  7.     }
  8.     /**
  9.      * Get the data bound to the view instance.
  10.      *
  1.         // clear out the sections for any separate views that may be rendered.
  2.         $this->factory->incrementRender();
  3.         $this->factory->callComposer($this);
  4.         $contents = $this->getContents();
  5.         // Once we've finished rendering the view, we'll decrement the render count
  6.         // so that each sections get flushed out next time a view is created and
  7.         // no old sections are staying around in the memory of an environment.
  8.         $this->factory->decrementRender();
  1.      * @throws \Throwable
  2.      */
  3.     public function render(callable $callback = null)
  4.     {
  5.         try {
  6.             $contents = $this->renderContents();
  7.             $response = isset($callback) ? $callback($this, $contents) : null;
  8.             // Once we have the contents of the view, we will flush the sections if we are
  9.             // done rendering all views so that there is nothing left hanging over when
  1.         display: none;
  2.     }
  3. }
  4. </style>
  5. <?php $__env->stopPush(); ?>
  6. <?php echo $__env->make('layouts.default-new', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH /var/www/dealsbarter2/resources/views/pages/404.blade.php ENDPATH**/ ?>
  1.             $__data = $data;
  2.             return (static function () use ($__path, $__data) {
  3.                 extract($__data, EXTR_SKIP);
  4.                 return require $__path;
  5.             })();
  6.         }
  7.         throw new FileNotFoundException("File does not exist at path {$path}.");
  8.     }
  1.             return (static function () use ($__path, $__data) {
  2.                 extract($__data, EXTR_SKIP);
  3.                 return require $__path;
  4.             })();
  5.         }
  6.         throw new FileNotFoundException("File does not exist at path {$path}.");
  7.     }
  1.         // We'll evaluate the contents of the view inside a try/catch block so we can
  2.         // flush out any stray output that might get out before an error occurs or
  3.         // an exception is thrown. This prevents any partial views from leaking.
  4.         try {
  5.             $this->files->getRequire($path, $data);
  6.         } catch (Throwable $e) {
  7.             $this->handleViewException($e, $obLevel);
  8.         }
  9.         return ltrim(ob_get_clean());
  1.         }
  2.         // Once we have the path to the compiled file, we will evaluate the paths with
  3.         // typical PHP just like any other templates. We also keep a stack of views
  4.         // which have been rendered for right exception messages to be generated.
  5.         $results = $this->evaluatePath($this->compiler->getCompiledPath($path), $data);
  6.         array_pop($this->lastCompiled);
  7.         return $results;
  8.     }
  1.      *
  2.      * @return string
  3.      */
  4.     protected function getContents()
  5.     {
  6.         return $this->engine->get($this->path, $this->gatherData());
  7.     }
  8.     /**
  9.      * Get the data bound to the view instance.
  10.      *
  1.         // clear out the sections for any separate views that may be rendered.
  2.         $this->factory->incrementRender();
  3.         $this->factory->callComposer($this);
  4.         $contents = $this->getContents();
  5.         // Once we've finished rendering the view, we'll decrement the render count
  6.         // so that each sections get flushed out next time a view is created and
  7.         // no old sections are staying around in the memory of an environment.
  8.         $this->factory->decrementRender();
  1.      * @throws \Throwable
  2.      */
  3.     public function render(callable $callback = null)
  4.     {
  5.         try {
  6.             $contents = $this->renderContents();
  7.             $response = isset($callback) ? $callback($this, $contents) : null;
  8.             // Once we have the contents of the view, we will flush the sections if we are
  9.             // done rendering all views so that there is nothing left hanging over when
  1.         // If this content implements the "Renderable" interface then we will call the
  2.         // render method on the object so we will avoid any "__toString" exceptions
  3.         // that might be thrown and have their errors obscured by PHP's handling.
  4.         elseif ($content instanceof Renderable) {
  5.             $content = $content->render();
  6.         }
  7.         parent::setContent($content);
  8.         return $this;
  1.      */
  2.     public function __construct($content = '', $status = 200, array $headers = [])
  3.     {
  4.         $this->headers = new ResponseHeaderBag($headers);
  5.         $this->setContent($content);
  6.         $this->setStatusCode($status);
  7.         $this->setProtocolVersion('1.0');
  8.     }
  9.     /**
  1.      * @param  array  $headers
  2.      * @return \Illuminate\Http\Response
  3.      */
  4.     public function make($content = '', $status = 200, array $headers = [])
  5.     {
  6.         return new Response($content, $status, $headers);
  7.     }
  8.     /**
  9.      * Create a new "no content" response.
  10.      *
  1.     {
  2.         if (is_array($view)) {
  3.             return $this->make($this->view->first($view, $data), $status, $headers);
  4.         }
  5.         return $this->make($this->view->make($view, $data), $status, $headers);
  6.     }
  7.     /**
  8.      * Create a new JSON response instance.
  9.      *
ResponseFactory->view() in /var/www/dealsbarter2/app/Exceptions/Handler.php (line 55)
  1.      * @throws \Throwable
  2.      */
  3.     public function render($request, Throwable $exception)
  4.     {
  5.         if ($exception instanceof NotFoundHttpException) {
  6.             return response()->view('pages.404', compact('exception'), 404);
  7.         }
  8.         return parent::render($request, $exception);
  9.     }
  10. }
  1.         $handler = $this->container->make(ExceptionHandler::class);
  2.         $handler->report($e);
  3.         $response = $handler->render($passable, $e);
  4.         if (is_object($response) && method_exists($response, 'withException')) {
  5.             $response->withException($e);
  6.         }
  1.     {
  2.         return function ($passable) use ($destination) {
  3.             try {
  4.                 return $destination($passable);
  5.             } catch (Throwable $e) {
  6.                 return $this->handleException($passable, $e);
  7.             }
  8.         };
  9.     }
  10.     /**
Pipeline->Illuminate\Pipeline\{closure}() in /var/www/dealsbarter2/app/Http/Middleware/RedirectIfMatched.php (line 29)
  1.     if ($redirect) {
  2.         return response()->view('pages.redirect', ['newUrl' => $redirect->new_url]);
  3.     }
  4.     return $next($request);
  5. }
  6. }
  1.                         // since the object we're given was already a fully instantiated object.
  2.                         $parameters = [$passable, $stack];
  3.                     }
  4.                     $carry = method_exists($pipe, $this->method)
  5.                                     ? $pipe->{$this->method}(...$parameters)
  6.                                     : $pipe(...$parameters);
  7.                     return $this->handleCarry($carry);
  8.                 } catch (Throwable $e) {
  9.                     return $this->handleException($passable, $e);
  1.      */
  2.     public function handle($request, Closure $next)
  3.     {
  4.         $this->clean($request);
  5.         return $next($request);
  6.     }
  7.     /**
  8.      * Clean the request's data.
  9.      *
  1.             if ($callback($request)) {
  2.                 return $next($request);
  3.             }
  4.         }
  5.         return parent::handle($request, $next);
  6.     }
  7.     /**
  8.      * Transform the given value.
  9.      *
  1.                         // since the object we're given was already a fully instantiated object.
  2.                         $parameters = [$passable, $stack];
  3.                     }
  4.                     $carry = method_exists($pipe, $this->method)
  5.                                     ? $pipe->{$this->method}(...$parameters)
  6.                                     : $pipe(...$parameters);
  7.                     return $this->handleCarry($carry);
  8.                 } catch (Throwable $e) {
  9.                     return $this->handleException($passable, $e);
  1.      */
  2.     public function handle($request, Closure $next)
  3.     {
  4.         $this->clean($request);
  5.         return $next($request);
  6.     }
  7.     /**
  8.      * Clean the request's data.
  9.      *
  1.             if ($callback($request)) {
  2.                 return $next($request);
  3.             }
  4.         }
  5.         return parent::handle($request, $next);
  6.     }
  7.     /**
  8.      * Transform the given value.
  9.      *
  1.                         // since the object we're given was already a fully instantiated object.
  2.                         $parameters = [$passable, $stack];
  3.                     }
  4.                     $carry = method_exists($pipe, $this->method)
  5.                                     ? $pipe->{$this->method}(...$parameters)
  6.                                     : $pipe(...$parameters);
  7.                     return $this->handleCarry($carry);
  8.                 } catch (Throwable $e) {
  9.                     return $this->handleException($passable, $e);
  1.         if ($max > 0 && $request->server('CONTENT_LENGTH') > $max) {
  2.             throw new PostTooLargeException;
  3.         }
  4.         return $next($request);
  5.     }
  6.     /**
  7.      * Determine the server 'post_max_size' as bytes.
  8.      *
  1.                         // since the object we're given was already a fully instantiated object.
  2.                         $parameters = [$passable, $stack];
  3.                     }
  4.                     $carry = method_exists($pipe, $this->method)
  5.                                     ? $pipe->{$this->method}(...$parameters)
  6.                                     : $pipe(...$parameters);
  7.                     return $this->handleCarry($carry);
  8.                 } catch (Throwable $e) {
  9.                     return $this->handleException($passable, $e);
  1.                 null,
  2.                 $this->getHeaders($data)
  3.             );
  4.         }
  5.         return $next($request);
  6.     }
  7.     /**
  8.      * Determine if the incoming request has a maintenance mode bypass cookie.
  9.      *
  1.                         // since the object we're given was already a fully instantiated object.
  2.                         $parameters = [$passable, $stack];
  3.                     }
  4.                     $carry = method_exists($pipe, $this->method)
  5.                                     ? $pipe->{$this->method}(...$parameters)
  6.                                     : $pipe(...$parameters);
  7.                     return $this->handleCarry($carry);
  8.                 } catch (Throwable $e) {
  9.                     return $this->handleException($passable, $e);
  1.      */
  2.     public function handle($request, Closure $next)
  3.     {
  4.         // Check if we're dealing with CORS and if we should handle it
  5.         if (! $this->shouldRun($request)) {
  6.             return $next($request);
  7.         }
  8.         // For Preflight, return the Preflight response
  9.         if ($this->cors->isPreflightRequest($request)) {
  10.             $response = $this->cors->handlePreflightRequest($request);
  1.                         // since the object we're given was already a fully instantiated object.
  2.                         $parameters = [$passable, $stack];
  3.                     }
  4.                     $carry = method_exists($pipe, $this->method)
  5.                                     ? $pipe->{$this->method}(...$parameters)
  6.                                     : $pipe(...$parameters);
  7.                     return $this->handleCarry($carry);
  8.                 } catch (Throwable $e) {
  9.                     return $this->handleException($passable, $e);
  1.     {
  2.         $request::setTrustedProxies([], $this->getTrustedHeaderNames());
  3.         $this->setTrustedProxyIpAddresses($request);
  4.         return $next($request);
  5.     }
  6.     /**
  7.      * Sets the trusted proxies on the request.
  8.      *
  1.                         // since the object we're given was already a fully instantiated object.
  2.                         $parameters = [$passable, $stack];
  3.                     }
  4.                     $carry = method_exists($pipe, $this->method)
  5.                                     ? $pipe->{$this->method}(...$parameters)
  6.                                     : $pipe(...$parameters);
  7.                     return $this->handleCarry($carry);
  8.                 } catch (Throwable $e) {
  9.                     return $this->handleException($passable, $e);
  1.     {
  2.         $pipeline = array_reduce(
  3.             array_reverse($this->pipes()), $this->carry(), $this->prepareDestination($destination)
  4.         );
  5.         return $pipeline($this->passable);
  6.     }
  7.     /**
  8.      * Run the pipeline and return the result.
  9.      *
  1.         $this->bootstrap();
  2.         return (new Pipeline($this->app))
  3.                     ->send($request)
  4.                     ->through($this->app->shouldSkipMiddleware() ? [] : $this->middleware)
  5.                     ->then($this->dispatchToRouter());
  6.     }
  7.     /**
  8.      * Bootstrap the application for HTTP requests.
  9.      *
  1.     public function handle($request)
  2.     {
  3.         try {
  4.             $request->enableHttpMethodParameterOverride();
  5.             $response = $this->sendRequestThroughRouter($request);
  6.         } catch (Throwable $e) {
  7.             $this->reportException($e);
  8.             $response = $this->renderException($request, $e);
  9.         }
Kernel->handle() in /var/www/dealsbarter2/public/index.php (line 51)
  1. $app = require_once __DIR__.'/../bootstrap/app.php';
  2. $kernel = $app->make(Kernel::class);
  3. $response = $kernel->handle(
  4.     $request = Request::capture()
  5. )->send();
  6. $kernel->terminate($request, $response);

Illuminate\View\ ViewException

Route [logout] not defined. (View: /var/www/dealsbarter2/resources/views/elements/navbar.blade.php)

  1.     {
  2.         if (! is_null($route = $this->routes->getByName($name))) {
  3.             return $this->toRoute($route, $parameters, $absolute);
  4.         }
  5.         throw new RouteNotFoundException("Route [{$name}] not defined.");
  6.     }
  7.     /**
  8.      * Get the URL for a given route instance.
  9.      *
  1.         // flush out any stray output that might get out before an error occurs or
  2.         // an exception is thrown. This prevents any partial views from leaking.
  3.         try {
  4.             $this->files->getRequire($path, $data);
  5.         } catch (Throwable $e) {
  6.             $this->handleViewException($e, $obLevel);
  7.         }
  8.         return ltrim(ob_get_clean());
  9.     }
  1.         }
  2.         // Once we have the path to the compiled file, we will evaluate the paths with
  3.         // typical PHP just like any other templates. We also keep a stack of views
  4.         // which have been rendered for right exception messages to be generated.
  5.         $results = $this->evaluatePath($this->compiler->getCompiledPath($path), $data);
  6.         array_pop($this->lastCompiled);
  7.         return $results;
  8.     }
  1.      *
  2.      * @return string
  3.      */
  4.     protected function getContents()
  5.     {
  6.         return $this->engine->get($this->path, $this->gatherData());
  7.     }
  8.     /**
  9.      * Get the data bound to the view instance.
  10.      *
  1.         // clear out the sections for any separate views that may be rendered.
  2.         $this->factory->incrementRender();
  3.         $this->factory->callComposer($this);
  4.         $contents = $this->getContents();
  5.         // Once we've finished rendering the view, we'll decrement the render count
  6.         // so that each sections get flushed out next time a view is created and
  7.         // no old sections are staying around in the memory of an environment.
  8.         $this->factory->decrementRender();
  1.      * @throws \Throwable
  2.      */
  3.     public function render(callable $callback = null)
  4.     {
  5.         try {
  6.             $contents = $this->renderContents();
  7.             $response = isset($callback) ? $callback($this, $contents) : null;
  8.             // Once we have the contents of the view, we will flush the sections if we are
  9.             // done rendering all views so that there is nothing left hanging over when
  1.     "
  2. >
  3.     <div class="nhz-wrapper">
  4.         <?php echo $__env->make('elements.navbar', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?>
  5.         
  6.         
  1.             $__data = $data;
  2.             return (static function () use ($__path, $__data) {
  3.                 extract($__data, EXTR_SKIP);
  4.                 return require $__path;
  5.             })();
  6.         }
  7.         throw new FileNotFoundException("File does not exist at path {$path}.");
  8.     }
  1.             return (static function () use ($__path, $__data) {
  2.                 extract($__data, EXTR_SKIP);
  3.                 return require $__path;
  4.             })();
  5.         }
  6.         throw new FileNotFoundException("File does not exist at path {$path}.");
  7.     }
  1.         // We'll evaluate the contents of the view inside a try/catch block so we can
  2.         // flush out any stray output that might get out before an error occurs or
  3.         // an exception is thrown. This prevents any partial views from leaking.
  4.         try {
  5.             $this->files->getRequire($path, $data);
  6.         } catch (Throwable $e) {
  7.             $this->handleViewException($e, $obLevel);
  8.         }
  9.         return ltrim(ob_get_clean());
  1.         }
  2.         // Once we have the path to the compiled file, we will evaluate the paths with
  3.         // typical PHP just like any other templates. We also keep a stack of views
  4.         // which have been rendered for right exception messages to be generated.
  5.         $results = $this->evaluatePath($this->compiler->getCompiledPath($path), $data);
  6.         array_pop($this->lastCompiled);
  7.         return $results;
  8.     }
  1.      *
  2.      * @return string
  3.      */
  4.     protected function getContents()
  5.     {
  6.         return $this->engine->get($this->path, $this->gatherData());
  7.     }
  8.     /**
  9.      * Get the data bound to the view instance.
  10.      *
  1.         // clear out the sections for any separate views that may be rendered.
  2.         $this->factory->incrementRender();
  3.         $this->factory->callComposer($this);
  4.         $contents = $this->getContents();
  5.         // Once we've finished rendering the view, we'll decrement the render count
  6.         // so that each sections get flushed out next time a view is created and
  7.         // no old sections are staying around in the memory of an environment.
  8.         $this->factory->decrementRender();
  1.      * @throws \Throwable
  2.      */
  3.     public function render(callable $callback = null)
  4.     {
  5.         try {
  6.             $contents = $this->renderContents();
  7.             $response = isset($callback) ? $callback($this, $contents) : null;
  8.             // Once we have the contents of the view, we will flush the sections if we are
  9.             // done rendering all views so that there is nothing left hanging over when
  1.         display: none;
  2.     }
  3. }
  4. </style>
  5. <?php $__env->stopPush(); ?>
  6. <?php echo $__env->make('layouts.default-new', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH /var/www/dealsbarter2/resources/views/pages/404.blade.php ENDPATH**/ ?>
  1.             $__data = $data;
  2.             return (static function () use ($__path, $__data) {
  3.                 extract($__data, EXTR_SKIP);
  4.                 return require $__path;
  5.             })();
  6.         }
  7.         throw new FileNotFoundException("File does not exist at path {$path}.");
  8.     }
  1.             return (static function () use ($__path, $__data) {
  2.                 extract($__data, EXTR_SKIP);
  3.                 return require $__path;
  4.             })();
  5.         }
  6.         throw new FileNotFoundException("File does not exist at path {$path}.");
  7.     }
  1.         // We'll evaluate the contents of the view inside a try/catch block so we can
  2.         // flush out any stray output that might get out before an error occurs or
  3.         // an exception is thrown. This prevents any partial views from leaking.
  4.         try {
  5.             $this->files->getRequire($path, $data);
  6.         } catch (Throwable $e) {
  7.             $this->handleViewException($e, $obLevel);
  8.         }
  9.         return ltrim(ob_get_clean());
  1.         }
  2.         // Once we have the path to the compiled file, we will evaluate the paths with
  3.         // typical PHP just like any other templates. We also keep a stack of views
  4.         // which have been rendered for right exception messages to be generated.
  5.         $results = $this->evaluatePath($this->compiler->getCompiledPath($path), $data);
  6.         array_pop($this->lastCompiled);
  7.         return $results;
  8.     }
  1.      *
  2.      * @return string
  3.      */
  4.     protected function getContents()
  5.     {
  6.         return $this->engine->get($this->path, $this->gatherData());
  7.     }
  8.     /**
  9.      * Get the data bound to the view instance.
  10.      *
  1.         // clear out the sections for any separate views that may be rendered.
  2.         $this->factory->incrementRender();
  3.         $this->factory->callComposer($this);
  4.         $contents = $this->getContents();
  5.         // Once we've finished rendering the view, we'll decrement the render count
  6.         // so that each sections get flushed out next time a view is created and
  7.         // no old sections are staying around in the memory of an environment.
  8.         $this->factory->decrementRender();
  1.      * @throws \Throwable
  2.      */
  3.     public function render(callable $callback = null)
  4.     {
  5.         try {
  6.             $contents = $this->renderContents();
  7.             $response = isset($callback) ? $callback($this, $contents) : null;
  8.             // Once we have the contents of the view, we will flush the sections if we are
  9.             // done rendering all views so that there is nothing left hanging over when
  1.         // If this content implements the "Renderable" interface then we will call the
  2.         // render method on the object so we will avoid any "__toString" exceptions
  3.         // that might be thrown and have their errors obscured by PHP's handling.
  4.         elseif ($content instanceof Renderable) {
  5.             $content = $content->render();
  6.         }
  7.         parent::setContent($content);
  8.         return $this;
  1.      */
  2.     public function __construct($content = '', $status = 200, array $headers = [])
  3.     {
  4.         $this->headers = new ResponseHeaderBag($headers);
  5.         $this->setContent($content);
  6.         $this->setStatusCode($status);
  7.         $this->setProtocolVersion('1.0');
  8.     }
  9.     /**
  1.      * @param  array  $headers
  2.      * @return \Illuminate\Http\Response
  3.      */
  4.     public function make($content = '', $status = 200, array $headers = [])
  5.     {
  6.         return new Response($content, $status, $headers);
  7.     }
  8.     /**
  9.      * Create a new "no content" response.
  10.      *
  1.     {
  2.         if (is_array($view)) {
  3.             return $this->make($this->view->first($view, $data), $status, $headers);
  4.         }
  5.         return $this->make($this->view->make($view, $data), $status, $headers);
  6.     }
  7.     /**
  8.      * Create a new JSON response instance.
  9.      *
ResponseFactory->view() in /var/www/dealsbarter2/app/Exceptions/Handler.php (line 55)
  1.      * @throws \Throwable
  2.      */
  3.     public function render($request, Throwable $exception)
  4.     {
  5.         if ($exception instanceof NotFoundHttpException) {
  6.             return response()->view('pages.404', compact('exception'), 404);
  7.         }
  8.         return parent::render($request, $exception);
  9.     }
  10. }
  1.         $handler = $this->container->make(ExceptionHandler::class);
  2.         $handler->report($e);
  3.         $response = $handler->render($passable, $e);
  4.         if (is_object($response) && method_exists($response, 'withException')) {
  5.             $response->withException($e);
  6.         }
  1.     {
  2.         return function ($passable) use ($destination) {
  3.             try {
  4.                 return $destination($passable);
  5.             } catch (Throwable $e) {
  6.                 return $this->handleException($passable, $e);
  7.             }
  8.         };
  9.     }
  10.     /**
Pipeline->Illuminate\Pipeline\{closure}() in /var/www/dealsbarter2/app/Http/Middleware/RedirectIfMatched.php (line 29)
  1.     if ($redirect) {
  2.         return response()->view('pages.redirect', ['newUrl' => $redirect->new_url]);
  3.     }
  4.     return $next($request);
  5. }
  6. }
  1.                         // since the object we're given was already a fully instantiated object.
  2.                         $parameters = [$passable, $stack];
  3.                     }
  4.                     $carry = method_exists($pipe, $this->method)
  5.                                     ? $pipe->{$this->method}(...$parameters)
  6.                                     : $pipe(...$parameters);
  7.                     return $this->handleCarry($carry);
  8.                 } catch (Throwable $e) {
  9.                     return $this->handleException($passable, $e);
  1.      */
  2.     public function handle($request, Closure $next)
  3.     {
  4.         $this->clean($request);
  5.         return $next($request);
  6.     }
  7.     /**
  8.      * Clean the request's data.
  9.      *
  1.             if ($callback($request)) {
  2.                 return $next($request);
  3.             }
  4.         }
  5.         return parent::handle($request, $next);
  6.     }
  7.     /**
  8.      * Transform the given value.
  9.      *
  1.                         // since the object we're given was already a fully instantiated object.
  2.                         $parameters = [$passable, $stack];
  3.                     }
  4.                     $carry = method_exists($pipe, $this->method)
  5.                                     ? $pipe->{$this->method}(...$parameters)
  6.                                     : $pipe(...$parameters);
  7.                     return $this->handleCarry($carry);
  8.                 } catch (Throwable $e) {
  9.                     return $this->handleException($passable, $e);
  1.      */
  2.     public function handle($request, Closure $next)
  3.     {
  4.         $this->clean($request);
  5.         return $next($request);
  6.     }
  7.     /**
  8.      * Clean the request's data.
  9.      *
  1.             if ($callback($request)) {
  2.                 return $next($request);
  3.             }
  4.         }
  5.         return parent::handle($request, $next);
  6.     }
  7.     /**
  8.      * Transform the given value.
  9.      *
  1.                         // since the object we're given was already a fully instantiated object.
  2.                         $parameters = [$passable, $stack];
  3.                     }
  4.                     $carry = method_exists($pipe, $this->method)
  5.                                     ? $pipe->{$this->method}(...$parameters)
  6.                                     : $pipe(...$parameters);
  7.                     return $this->handleCarry($carry);
  8.                 } catch (Throwable $e) {
  9.                     return $this->handleException($passable, $e);
  1.         if ($max > 0 && $request->server('CONTENT_LENGTH') > $max) {
  2.             throw new PostTooLargeException;
  3.         }
  4.         return $next($request);
  5.     }
  6.     /**
  7.      * Determine the server 'post_max_size' as bytes.
  8.      *
  1.                         // since the object we're given was already a fully instantiated object.
  2.                         $parameters = [$passable, $stack];
  3.                     }
  4.                     $carry = method_exists($pipe, $this->method)
  5.                                     ? $pipe->{$this->method}(...$parameters)
  6.                                     : $pipe(...$parameters);
  7.                     return $this->handleCarry($carry);
  8.                 } catch (Throwable $e) {
  9.                     return $this->handleException($passable, $e);
  1.                 null,
  2.                 $this->getHeaders($data)
  3.             );
  4.         }
  5.         return $next($request);
  6.     }
  7.     /**
  8.      * Determine if the incoming request has a maintenance mode bypass cookie.
  9.      *
  1.                         // since the object we're given was already a fully instantiated object.
  2.                         $parameters = [$passable, $stack];
  3.                     }
  4.                     $carry = method_exists($pipe, $this->method)
  5.                                     ? $pipe->{$this->method}(...$parameters)
  6.                                     : $pipe(...$parameters);
  7.                     return $this->handleCarry($carry);
  8.                 } catch (Throwable $e) {
  9.                     return $this->handleException($passable, $e);
  1.      */
  2.     public function handle($request, Closure $next)
  3.     {
  4.         // Check if we're dealing with CORS and if we should handle it
  5.         if (! $this->shouldRun($request)) {
  6.             return $next($request);
  7.         }
  8.         // For Preflight, return the Preflight response
  9.         if ($this->cors->isPreflightRequest($request)) {
  10.             $response = $this->cors->handlePreflightRequest($request);
  1.                         // since the object we're given was already a fully instantiated object.
  2.                         $parameters = [$passable, $stack];
  3.                     }
  4.                     $carry = method_exists($pipe, $this->method)
  5.                                     ? $pipe->{$this->method}(...$parameters)
  6.                                     : $pipe(...$parameters);
  7.                     return $this->handleCarry($carry);
  8.                 } catch (Throwable $e) {
  9.                     return $this->handleException($passable, $e);
  1.     {
  2.         $request::setTrustedProxies([], $this->getTrustedHeaderNames());
  3.         $this->setTrustedProxyIpAddresses($request);
  4.         return $next($request);
  5.     }
  6.     /**
  7.      * Sets the trusted proxies on the request.
  8.      *
  1.                         // since the object we're given was already a fully instantiated object.
  2.                         $parameters = [$passable, $stack];
  3.                     }
  4.                     $carry = method_exists($pipe, $this->method)
  5.                                     ? $pipe->{$this->method}(...$parameters)
  6.                                     : $pipe(...$parameters);
  7.                     return $this->handleCarry($carry);
  8.                 } catch (Throwable $e) {
  9.                     return $this->handleException($passable, $e);
  1.     {
  2.         $pipeline = array_reduce(
  3.             array_reverse($this->pipes()), $this->carry(), $this->prepareDestination($destination)
  4.         );
  5.         return $pipeline($this->passable);
  6.     }
  7.     /**
  8.      * Run the pipeline and return the result.
  9.      *
  1.         $this->bootstrap();
  2.         return (new Pipeline($this->app))
  3.                     ->send($request)
  4.                     ->through($this->app->shouldSkipMiddleware() ? [] : $this->middleware)
  5.                     ->then($this->dispatchToRouter());
  6.     }
  7.     /**
  8.      * Bootstrap the application for HTTP requests.
  9.      *
  1.     public function handle($request)
  2.     {
  3.         try {
  4.             $request->enableHttpMethodParameterOverride();
  5.             $response = $this->sendRequestThroughRouter($request);
  6.         } catch (Throwable $e) {
  7.             $this->reportException($e);
  8.             $response = $this->renderException($request, $e);
  9.         }
Kernel->handle() in /var/www/dealsbarter2/public/index.php (line 51)
  1. $app = require_once __DIR__.'/../bootstrap/app.php';
  2. $kernel = $app->make(Kernel::class);
  3. $response = $kernel->handle(
  4.     $request = Request::capture()
  5. )->send();
  6. $kernel->terminate($request, $response);

Symfony\Component\Routing\Exception\ RouteNotFoundException

Route [logout] not defined.

  1.     {
  2.         if (! is_null($route = $this->routes->getByName($name))) {
  3.             return $this->toRoute($route, $parameters, $absolute);
  4.         }
  5.         throw new RouteNotFoundException("Route [{$name}] not defined.");
  6.     }
  7.     /**
  8.      * Get the URL for a given route instance.
  9.      *
  1.      * @param  bool  $absolute
  2.      * @return string
  3.      */
  4.     function route($name, $parameters = [], $absolute = true)
  5.     {
  6.         return app('url')->route($name, $parameters, $absolute);
  7.     }
  8. }
  9. if (! function_exists('secure_asset')) {
  10.     /**
  1.         <ul class="list-group">
  2.           <li class="list-group-item"><a href="/my-account/dashboard/">My Account</a></li>
  3.           <li class="list-group-item"><a href="/my-account/my-profile/">Update Profile</a></li>
  4.     <li class="list-group-item"><a href="/my-account/favourites/">My Favorites</a></li>
  5.           <li class="list-group-item">
  6.             <a href="<?php echo e(route('logout')); ?>">
  7.                Logout
  8.             </a>
  9.           </li>
  10.         </ul>
  11.       </div>
  1.             $__data = $data;
  2.             return (static function () use ($__path, $__data) {
  3.                 extract($__data, EXTR_SKIP);
  4.                 return require $__path;
  5.             })();
  6.         }
  7.         throw new FileNotFoundException("File does not exist at path {$path}.");
  8.     }
  1.             return (static function () use ($__path, $__data) {
  2.                 extract($__data, EXTR_SKIP);
  3.                 return require $__path;
  4.             })();
  5.         }
  6.         throw new FileNotFoundException("File does not exist at path {$path}.");
  7.     }
  1.         // We'll evaluate the contents of the view inside a try/catch block so we can
  2.         // flush out any stray output that might get out before an error occurs or
  3.         // an exception is thrown. This prevents any partial views from leaking.
  4.         try {
  5.             $this->files->getRequire($path, $data);
  6.         } catch (Throwable $e) {
  7.             $this->handleViewException($e, $obLevel);
  8.         }
  9.         return ltrim(ob_get_clean());
  1.         }
  2.         // Once we have the path to the compiled file, we will evaluate the paths with
  3.         // typical PHP just like any other templates. We also keep a stack of views
  4.         // which have been rendered for right exception messages to be generated.
  5.         $results = $this->evaluatePath($this->compiler->getCompiledPath($path), $data);
  6.         array_pop($this->lastCompiled);
  7.         return $results;
  8.     }
  1.      *
  2.      * @return string
  3.      */
  4.     protected function getContents()
  5.     {
  6.         return $this->engine->get($this->path, $this->gatherData());
  7.     }
  8.     /**
  9.      * Get the data bound to the view instance.
  10.      *
  1.         // clear out the sections for any separate views that may be rendered.
  2.         $this->factory->incrementRender();
  3.         $this->factory->callComposer($this);
  4.         $contents = $this->getContents();
  5.         // Once we've finished rendering the view, we'll decrement the render count
  6.         // so that each sections get flushed out next time a view is created and
  7.         // no old sections are staying around in the memory of an environment.
  8.         $this->factory->decrementRender();
  1.      * @throws \Throwable
  2.      */
  3.     public function render(callable $callback = null)
  4.     {
  5.         try {
  6.             $contents = $this->renderContents();
  7.             $response = isset($callback) ? $callback($this, $contents) : null;
  8.             // Once we have the contents of the view, we will flush the sections if we are
  9.             // done rendering all views so that there is nothing left hanging over when
  1.     "
  2. >
  3.     <div class="nhz-wrapper">
  4.         <?php echo $__env->make('elements.navbar', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?>
  5.         
  6.         
  1.             $__data = $data;
  2.             return (static function () use ($__path, $__data) {
  3.                 extract($__data, EXTR_SKIP);
  4.                 return require $__path;
  5.             })();
  6.         }
  7.         throw new FileNotFoundException("File does not exist at path {$path}.");
  8.     }
  1.             return (static function () use ($__path, $__data) {
  2.                 extract($__data, EXTR_SKIP);
  3.                 return require $__path;
  4.             })();
  5.         }
  6.         throw new FileNotFoundException("File does not exist at path {$path}.");
  7.     }
  1.         // We'll evaluate the contents of the view inside a try/catch block so we can
  2.         // flush out any stray output that might get out before an error occurs or
  3.         // an exception is thrown. This prevents any partial views from leaking.
  4.         try {
  5.             $this->files->getRequire($path, $data);
  6.         } catch (Throwable $e) {
  7.             $this->handleViewException($e, $obLevel);
  8.         }
  9.         return ltrim(ob_get_clean());
  1.         }
  2.         // Once we have the path to the compiled file, we will evaluate the paths with
  3.         // typical PHP just like any other templates. We also keep a stack of views
  4.         // which have been rendered for right exception messages to be generated.
  5.         $results = $this->evaluatePath($this->compiler->getCompiledPath($path), $data);
  6.         array_pop($this->lastCompiled);
  7.         return $results;
  8.     }
  1.      *
  2.      * @return string
  3.      */
  4.     protected function getContents()
  5.     {
  6.         return $this->engine->get($this->path, $this->gatherData());
  7.     }
  8.     /**
  9.      * Get the data bound to the view instance.
  10.      *
  1.         // clear out the sections for any separate views that may be rendered.
  2.         $this->factory->incrementRender();
  3.         $this->factory->callComposer($this);
  4.         $contents = $this->getContents();
  5.         // Once we've finished rendering the view, we'll decrement the render count
  6.         // so that each sections get flushed out next time a view is created and
  7.         // no old sections are staying around in the memory of an environment.
  8.         $this->factory->decrementRender();
  1.      * @throws \Throwable
  2.      */
  3.     public function render(callable $callback = null)
  4.     {
  5.         try {
  6.             $contents = $this->renderContents();
  7.             $response = isset($callback) ? $callback($this, $contents) : null;
  8.             // Once we have the contents of the view, we will flush the sections if we are
  9.             // done rendering all views so that there is nothing left hanging over when
  1.         display: none;
  2.     }
  3. }
  4. </style>
  5. <?php $__env->stopPush(); ?>
  6. <?php echo $__env->make('layouts.default-new', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH /var/www/dealsbarter2/resources/views/pages/404.blade.php ENDPATH**/ ?>
  1.             $__data = $data;
  2.             return (static function () use ($__path, $__data) {
  3.                 extract($__data, EXTR_SKIP);
  4.                 return require $__path;
  5.             })();
  6.         }
  7.         throw new FileNotFoundException("File does not exist at path {$path}.");
  8.     }
  1.             return (static function () use ($__path, $__data) {
  2.                 extract($__data, EXTR_SKIP);
  3.                 return require $__path;
  4.             })();
  5.         }
  6.         throw new FileNotFoundException("File does not exist at path {$path}.");
  7.     }
  1.         // We'll evaluate the contents of the view inside a try/catch block so we can
  2.         // flush out any stray output that might get out before an error occurs or
  3.         // an exception is thrown. This prevents any partial views from leaking.
  4.         try {
  5.             $this->files->getRequire($path, $data);
  6.         } catch (Throwable $e) {
  7.             $this->handleViewException($e, $obLevel);
  8.         }
  9.         return ltrim(ob_get_clean());
  1.         }
  2.         // Once we have the path to the compiled file, we will evaluate the paths with
  3.         // typical PHP just like any other templates. We also keep a stack of views
  4.         // which have been rendered for right exception messages to be generated.
  5.         $results = $this->evaluatePath($this->compiler->getCompiledPath($path), $data);
  6.         array_pop($this->lastCompiled);
  7.         return $results;
  8.     }
  1.      *
  2.      * @return string
  3.      */
  4.     protected function getContents()
  5.     {
  6.         return $this->engine->get($this->path, $this->gatherData());
  7.     }
  8.     /**
  9.      * Get the data bound to the view instance.
  10.      *
  1.         // clear out the sections for any separate views that may be rendered.
  2.         $this->factory->incrementRender();
  3.         $this->factory->callComposer($this);
  4.         $contents = $this->getContents();
  5.         // Once we've finished rendering the view, we'll decrement the render count
  6.         // so that each sections get flushed out next time a view is created and
  7.         // no old sections are staying around in the memory of an environment.
  8.         $this->factory->decrementRender();
  1.      * @throws \Throwable
  2.      */
  3.     public function render(callable $callback = null)
  4.     {
  5.         try {
  6.             $contents = $this->renderContents();
  7.             $response = isset($callback) ? $callback($this, $contents) : null;
  8.             // Once we have the contents of the view, we will flush the sections if we are
  9.             // done rendering all views so that there is nothing left hanging over when
  1.         // If this content implements the "Renderable" interface then we will call the
  2.         // render method on the object so we will avoid any "__toString" exceptions
  3.         // that might be thrown and have their errors obscured by PHP's handling.
  4.         elseif ($content instanceof Renderable) {
  5.             $content = $content->render();
  6.         }
  7.         parent::setContent($content);
  8.         return $this;
  1.      */
  2.     public function __construct($content = '', $status = 200, array $headers = [])
  3.     {
  4.         $this->headers = new ResponseHeaderBag($headers);
  5.         $this->setContent($content);
  6.         $this->setStatusCode($status);
  7.         $this->setProtocolVersion('1.0');
  8.     }
  9.     /**
  1.      * @param  array  $headers
  2.      * @return \Illuminate\Http\Response
  3.      */
  4.     public function make($content = '', $status = 200, array $headers = [])
  5.     {
  6.         return new Response($content, $status, $headers);
  7.     }
  8.     /**
  9.      * Create a new "no content" response.
  10.      *
  1.     {
  2.         if (is_array($view)) {
  3.             return $this->make($this->view->first($view, $data), $status, $headers);
  4.         }
  5.         return $this->make($this->view->make($view, $data), $status, $headers);
  6.     }
  7.     /**
  8.      * Create a new JSON response instance.
  9.      *
ResponseFactory->view() in /var/www/dealsbarter2/app/Exceptions/Handler.php (line 55)
  1.      * @throws \Throwable
  2.      */
  3.     public function render($request, Throwable $exception)
  4.     {
  5.         if ($exception instanceof NotFoundHttpException) {
  6.             return response()->view('pages.404', compact('exception'), 404);
  7.         }
  8.         return parent::render($request, $exception);
  9.     }
  10. }
  1.         $handler = $this->container->make(ExceptionHandler::class);
  2.         $handler->report($e);
  3.         $response = $handler->render($passable, $e);
  4.         if (is_object($response) && method_exists($response, 'withException')) {
  5.             $response->withException($e);
  6.         }
  1.     {
  2.         return function ($passable) use ($destination) {
  3.             try {
  4.                 return $destination($passable);
  5.             } catch (Throwable $e) {
  6.                 return $this->handleException($passable, $e);
  7.             }
  8.         };
  9.     }
  10.     /**
Pipeline->Illuminate\Pipeline\{closure}() in /var/www/dealsbarter2/app/Http/Middleware/RedirectIfMatched.php (line 29)
  1.     if ($redirect) {
  2.         return response()->view('pages.redirect', ['newUrl' => $redirect->new_url]);
  3.     }
  4.     return $next($request);
  5. }
  6. }
  1.                         // since the object we're given was already a fully instantiated object.
  2.                         $parameters = [$passable, $stack];
  3.                     }
  4.                     $carry = method_exists($pipe, $this->method)
  5.                                     ? $pipe->{$this->method}(...$parameters)
  6.                                     : $pipe(...$parameters);
  7.                     return $this->handleCarry($carry);
  8.                 } catch (Throwable $e) {
  9.                     return $this->handleException($passable, $e);
  1.      */
  2.     public function handle($request, Closure $next)
  3.     {
  4.         $this->clean($request);
  5.         return $next($request);
  6.     }
  7.     /**
  8.      * Clean the request's data.
  9.      *
  1.             if ($callback($request)) {
  2.                 return $next($request);
  3.             }
  4.         }
  5.         return parent::handle($request, $next);
  6.     }
  7.     /**
  8.      * Transform the given value.
  9.      *
  1.                         // since the object we're given was already a fully instantiated object.
  2.                         $parameters = [$passable, $stack];
  3.                     }
  4.                     $carry = method_exists($pipe, $this->method)
  5.                                     ? $pipe->{$this->method}(...$parameters)
  6.                                     : $pipe(...$parameters);
  7.                     return $this->handleCarry($carry);
  8.                 } catch (Throwable $e) {
  9.                     return $this->handleException($passable, $e);
  1.      */
  2.     public function handle($request, Closure $next)
  3.     {
  4.         $this->clean($request);
  5.         return $next($request);
  6.     }
  7.     /**
  8.      * Clean the request's data.
  9.      *
  1.             if ($callback($request)) {
  2.                 return $next($request);
  3.             }
  4.         }
  5.         return parent::handle($request, $next);
  6.     }
  7.     /**
  8.      * Transform the given value.
  9.      *
  1.                         // since the object we're given was already a fully instantiated object.
  2.                         $parameters = [$passable, $stack];
  3.                     }
  4.                     $carry = method_exists($pipe, $this->method)
  5.                                     ? $pipe->{$this->method}(...$parameters)
  6.                                     : $pipe(...$parameters);
  7.                     return $this->handleCarry($carry);
  8.                 } catch (Throwable $e) {
  9.                     return $this->handleException($passable, $e);
  1.         if ($max > 0 && $request->server('CONTENT_LENGTH') > $max) {
  2.             throw new PostTooLargeException;
  3.         }
  4.         return $next($request);
  5.     }
  6.     /**
  7.      * Determine the server 'post_max_size' as bytes.
  8.      *
  1.                         // since the object we're given was already a fully instantiated object.
  2.                         $parameters = [$passable, $stack];
  3.                     }
  4.                     $carry = method_exists($pipe, $this->method)
  5.                                     ? $pipe->{$this->method}(...$parameters)
  6.                                     : $pipe(...$parameters);
  7.                     return $this->handleCarry($carry);
  8.                 } catch (Throwable $e) {
  9.                     return $this->handleException($passable, $e);
  1.                 null,
  2.                 $this->getHeaders($data)
  3.             );
  4.         }
  5.         return $next($request);
  6.     }
  7.     /**
  8.      * Determine if the incoming request has a maintenance mode bypass cookie.
  9.      *
  1.                         // since the object we're given was already a fully instantiated object.
  2.                         $parameters = [$passable, $stack];
  3.                     }
  4.                     $carry = method_exists($pipe, $this->method)
  5.                                     ? $pipe->{$this->method}(...$parameters)
  6.                                     : $pipe(...$parameters);
  7.                     return $this->handleCarry($carry);
  8.                 } catch (Throwable $e) {
  9.                     return $this->handleException($passable, $e);
  1.      */
  2.     public function handle($request, Closure $next)
  3.     {
  4.         // Check if we're dealing with CORS and if we should handle it
  5.         if (! $this->shouldRun($request)) {
  6.             return $next($request);
  7.         }
  8.         // For Preflight, return the Preflight response
  9.         if ($this->cors->isPreflightRequest($request)) {
  10.             $response = $this->cors->handlePreflightRequest($request);
  1.                         // since the object we're given was already a fully instantiated object.
  2.                         $parameters = [$passable, $stack];
  3.                     }
  4.                     $carry = method_exists($pipe, $this->method)
  5.                                     ? $pipe->{$this->method}(...$parameters)
  6.                                     : $pipe(...$parameters);
  7.                     return $this->handleCarry($carry);
  8.                 } catch (Throwable $e) {
  9.                     return $this->handleException($passable, $e);
  1.     {
  2.         $request::setTrustedProxies([], $this->getTrustedHeaderNames());
  3.         $this->setTrustedProxyIpAddresses($request);
  4.         return $next($request);
  5.     }
  6.     /**
  7.      * Sets the trusted proxies on the request.
  8.      *
  1.                         // since the object we're given was already a fully instantiated object.
  2.                         $parameters = [$passable, $stack];
  3.                     }
  4.                     $carry = method_exists($pipe, $this->method)
  5.                                     ? $pipe->{$this->method}(...$parameters)
  6.                                     : $pipe(...$parameters);
  7.                     return $this->handleCarry($carry);
  8.                 } catch (Throwable $e) {
  9.                     return $this->handleException($passable, $e);
  1.     {
  2.         $pipeline = array_reduce(
  3.             array_reverse($this->pipes()), $this->carry(), $this->prepareDestination($destination)
  4.         );
  5.         return $pipeline($this->passable);
  6.     }
  7.     /**
  8.      * Run the pipeline and return the result.
  9.      *
  1.         $this->bootstrap();
  2.         return (new Pipeline($this->app))
  3.                     ->send($request)
  4.                     ->through($this->app->shouldSkipMiddleware() ? [] : $this->middleware)
  5.                     ->then($this->dispatchToRouter());
  6.     }
  7.     /**
  8.      * Bootstrap the application for HTTP requests.
  9.      *
  1.     public function handle($request)
  2.     {
  3.         try {
  4.             $request->enableHttpMethodParameterOverride();
  5.             $response = $this->sendRequestThroughRouter($request);
  6.         } catch (Throwable $e) {
  7.             $this->reportException($e);
  8.             $response = $this->renderException($request, $e);
  9.         }
Kernel->handle() in /var/www/dealsbarter2/public/index.php (line 51)
  1. $app = require_once __DIR__.'/../bootstrap/app.php';
  2. $kernel = $app->make(Kernel::class);
  3. $response = $kernel->handle(
  4.     $request = Request::capture()
  5. )->send();
  6. $kernel->terminate($request, $response);

Stack Traces 4

[4/4] ViewException
Illuminate\View\ViewException:
Route [logout] not defined. (View: /var/www/dealsbarter2/resources/views/elements/navbar.blade.php) (View: /var/www/dealsbarter2/resources/views/elements/navbar.blade.php) (View: /var/www/dealsbarter2/resources/views/elements/navbar.blade.php)

  at /var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Routing/UrlGenerator.php:444
  at Illuminate\View\Engines\CompilerEngine->handleViewException()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/Engines/PhpEngine.php:60)
  at Illuminate\View\Engines\PhpEngine->evaluatePath()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/Engines/CompilerEngine.php:61)
  at Illuminate\View\Engines\CompilerEngine->get()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/View.php:139)
  at Illuminate\View\View->getContents()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/View.php:122)
  at Illuminate\View\View->renderContents()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/View.php:91)
  at Illuminate\View\View->render()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Http/Response.php:69)
  at Illuminate\Http\Response->setContent()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Http/Response.php:35)
  at Illuminate\Http\Response->__construct()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Routing/ResponseFactory.php:55)
  at Illuminate\Routing\ResponseFactory->make()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Routing/ResponseFactory.php:85)
  at Illuminate\Routing\ResponseFactory->view()
     (/var/www/dealsbarter2/app/Exceptions/Handler.php:55)
  at App\Exceptions\Handler->render()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php:51)
  at Illuminate\Routing\Pipeline->handleException()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:130)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/app/Http/Middleware/RedirectIfMatched.php:29)
  at App\Http\Middleware\RedirectIfMatched->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TransformsRequest.php:21)
  at Illuminate\Foundation\Http\Middleware\TransformsRequest->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/ConvertEmptyStringsToNull.php:31)
  at Illuminate\Foundation\Http\Middleware\ConvertEmptyStringsToNull->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TransformsRequest.php:21)
  at Illuminate\Foundation\Http\Middleware\TransformsRequest->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TrimStrings.php:40)
  at Illuminate\Foundation\Http\Middleware\TrimStrings->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/ValidatePostSize.php:27)
  at Illuminate\Foundation\Http\Middleware\ValidatePostSize->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/PreventRequestsDuringMaintenance.php:86)
  at Illuminate\Foundation\Http\Middleware\PreventRequestsDuringMaintenance->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/vendor/fruitcake/laravel-cors/src/HandleCors.php:38)
  at Fruitcake\Cors\HandleCors->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Http/Middleware/TrustProxies.php:39)
  at Illuminate\Http\Middleware\TrustProxies->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:103)
  at Illuminate\Pipeline\Pipeline->then()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php:142)
  at Illuminate\Foundation\Http\Kernel->sendRequestThroughRouter()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php:111)
  at Illuminate\Foundation\Http\Kernel->handle()
     (/var/www/dealsbarter2/public/index.php:51)                
[3/4] ViewException
Illuminate\View\ViewException:
Route [logout] not defined. (View: /var/www/dealsbarter2/resources/views/elements/navbar.blade.php) (View: /var/www/dealsbarter2/resources/views/elements/navbar.blade.php)

  at /var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Routing/UrlGenerator.php:444
  at Illuminate\View\Engines\CompilerEngine->handleViewException()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/Engines/PhpEngine.php:60)
  at Illuminate\View\Engines\PhpEngine->evaluatePath()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/Engines/CompilerEngine.php:61)
  at Illuminate\View\Engines\CompilerEngine->get()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/View.php:139)
  at Illuminate\View\View->getContents()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/View.php:122)
  at Illuminate\View\View->renderContents()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/View.php:91)
  at Illuminate\View\View->render()
     (/var/www/dealsbarter2/storage/framework/views/08609d43a0e87c7fc29e8d33b7637a61f3b5a0f1.php:711)
  at require('/var/www/dealsbarter2/storage/framework/views/08609d43a0e87c7fc29e8d33b7637a61f3b5a0f1.php')
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Filesystem/Filesystem.php:107)
  at Illuminate\Filesystem\Filesystem::Illuminate\Filesystem\{closure}()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Filesystem/Filesystem.php:108)
  at Illuminate\Filesystem\Filesystem->getRequire()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/Engines/PhpEngine.php:58)
  at Illuminate\View\Engines\PhpEngine->evaluatePath()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/Engines/CompilerEngine.php:61)
  at Illuminate\View\Engines\CompilerEngine->get()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/View.php:139)
  at Illuminate\View\View->getContents()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/View.php:122)
  at Illuminate\View\View->renderContents()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/View.php:91)
  at Illuminate\View\View->render()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Http/Response.php:69)
  at Illuminate\Http\Response->setContent()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Http/Response.php:35)
  at Illuminate\Http\Response->__construct()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Routing/ResponseFactory.php:55)
  at Illuminate\Routing\ResponseFactory->make()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Routing/ResponseFactory.php:85)
  at Illuminate\Routing\ResponseFactory->view()
     (/var/www/dealsbarter2/app/Exceptions/Handler.php:55)
  at App\Exceptions\Handler->render()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php:51)
  at Illuminate\Routing\Pipeline->handleException()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:130)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/app/Http/Middleware/RedirectIfMatched.php:29)
  at App\Http\Middleware\RedirectIfMatched->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TransformsRequest.php:21)
  at Illuminate\Foundation\Http\Middleware\TransformsRequest->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/ConvertEmptyStringsToNull.php:31)
  at Illuminate\Foundation\Http\Middleware\ConvertEmptyStringsToNull->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TransformsRequest.php:21)
  at Illuminate\Foundation\Http\Middleware\TransformsRequest->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TrimStrings.php:40)
  at Illuminate\Foundation\Http\Middleware\TrimStrings->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/ValidatePostSize.php:27)
  at Illuminate\Foundation\Http\Middleware\ValidatePostSize->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/PreventRequestsDuringMaintenance.php:86)
  at Illuminate\Foundation\Http\Middleware\PreventRequestsDuringMaintenance->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/vendor/fruitcake/laravel-cors/src/HandleCors.php:38)
  at Fruitcake\Cors\HandleCors->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Http/Middleware/TrustProxies.php:39)
  at Illuminate\Http\Middleware\TrustProxies->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:103)
  at Illuminate\Pipeline\Pipeline->then()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php:142)
  at Illuminate\Foundation\Http\Kernel->sendRequestThroughRouter()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php:111)
  at Illuminate\Foundation\Http\Kernel->handle()
     (/var/www/dealsbarter2/public/index.php:51)                
[2/4] ViewException
Illuminate\View\ViewException:
Route [logout] not defined. (View: /var/www/dealsbarter2/resources/views/elements/navbar.blade.php)

  at /var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Routing/UrlGenerator.php:444
  at Illuminate\View\Engines\CompilerEngine->handleViewException()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/Engines/PhpEngine.php:60)
  at Illuminate\View\Engines\PhpEngine->evaluatePath()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/Engines/CompilerEngine.php:61)
  at Illuminate\View\Engines\CompilerEngine->get()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/View.php:139)
  at Illuminate\View\View->getContents()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/View.php:122)
  at Illuminate\View\View->renderContents()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/View.php:91)
  at Illuminate\View\View->render()
     (/var/www/dealsbarter2/storage/framework/views/acc66827d67507316afea850c2260a930f02b3c8.php:81)
  at require('/var/www/dealsbarter2/storage/framework/views/acc66827d67507316afea850c2260a930f02b3c8.php')
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Filesystem/Filesystem.php:107)
  at Illuminate\Filesystem\Filesystem::Illuminate\Filesystem\{closure}()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Filesystem/Filesystem.php:108)
  at Illuminate\Filesystem\Filesystem->getRequire()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/Engines/PhpEngine.php:58)
  at Illuminate\View\Engines\PhpEngine->evaluatePath()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/Engines/CompilerEngine.php:61)
  at Illuminate\View\Engines\CompilerEngine->get()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/View.php:139)
  at Illuminate\View\View->getContents()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/View.php:122)
  at Illuminate\View\View->renderContents()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/View.php:91)
  at Illuminate\View\View->render()
     (/var/www/dealsbarter2/storage/framework/views/08609d43a0e87c7fc29e8d33b7637a61f3b5a0f1.php:711)
  at require('/var/www/dealsbarter2/storage/framework/views/08609d43a0e87c7fc29e8d33b7637a61f3b5a0f1.php')
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Filesystem/Filesystem.php:107)
  at Illuminate\Filesystem\Filesystem::Illuminate\Filesystem\{closure}()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Filesystem/Filesystem.php:108)
  at Illuminate\Filesystem\Filesystem->getRequire()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/Engines/PhpEngine.php:58)
  at Illuminate\View\Engines\PhpEngine->evaluatePath()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/Engines/CompilerEngine.php:61)
  at Illuminate\View\Engines\CompilerEngine->get()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/View.php:139)
  at Illuminate\View\View->getContents()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/View.php:122)
  at Illuminate\View\View->renderContents()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/View.php:91)
  at Illuminate\View\View->render()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Http/Response.php:69)
  at Illuminate\Http\Response->setContent()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Http/Response.php:35)
  at Illuminate\Http\Response->__construct()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Routing/ResponseFactory.php:55)
  at Illuminate\Routing\ResponseFactory->make()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Routing/ResponseFactory.php:85)
  at Illuminate\Routing\ResponseFactory->view()
     (/var/www/dealsbarter2/app/Exceptions/Handler.php:55)
  at App\Exceptions\Handler->render()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php:51)
  at Illuminate\Routing\Pipeline->handleException()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:130)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/app/Http/Middleware/RedirectIfMatched.php:29)
  at App\Http\Middleware\RedirectIfMatched->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TransformsRequest.php:21)
  at Illuminate\Foundation\Http\Middleware\TransformsRequest->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/ConvertEmptyStringsToNull.php:31)
  at Illuminate\Foundation\Http\Middleware\ConvertEmptyStringsToNull->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TransformsRequest.php:21)
  at Illuminate\Foundation\Http\Middleware\TransformsRequest->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TrimStrings.php:40)
  at Illuminate\Foundation\Http\Middleware\TrimStrings->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/ValidatePostSize.php:27)
  at Illuminate\Foundation\Http\Middleware\ValidatePostSize->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/PreventRequestsDuringMaintenance.php:86)
  at Illuminate\Foundation\Http\Middleware\PreventRequestsDuringMaintenance->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/vendor/fruitcake/laravel-cors/src/HandleCors.php:38)
  at Fruitcake\Cors\HandleCors->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Http/Middleware/TrustProxies.php:39)
  at Illuminate\Http\Middleware\TrustProxies->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:103)
  at Illuminate\Pipeline\Pipeline->then()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php:142)
  at Illuminate\Foundation\Http\Kernel->sendRequestThroughRouter()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php:111)
  at Illuminate\Foundation\Http\Kernel->handle()
     (/var/www/dealsbarter2/public/index.php:51)                
[1/4] RouteNotFoundException
Symfony\Component\Routing\Exception\RouteNotFoundException:
Route [logout] not defined.

  at /var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Routing/UrlGenerator.php:444
  at Illuminate\Routing\UrlGenerator->route()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/helpers.php:739)
  at route()
     (/var/www/dealsbarter2/storage/framework/views/e7a0917564372493e0603de196c4e2ba4093ba52.php:29)
  at require('/var/www/dealsbarter2/storage/framework/views/e7a0917564372493e0603de196c4e2ba4093ba52.php')
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Filesystem/Filesystem.php:107)
  at Illuminate\Filesystem\Filesystem::Illuminate\Filesystem\{closure}()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Filesystem/Filesystem.php:108)
  at Illuminate\Filesystem\Filesystem->getRequire()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/Engines/PhpEngine.php:58)
  at Illuminate\View\Engines\PhpEngine->evaluatePath()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/Engines/CompilerEngine.php:61)
  at Illuminate\View\Engines\CompilerEngine->get()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/View.php:139)
  at Illuminate\View\View->getContents()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/View.php:122)
  at Illuminate\View\View->renderContents()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/View.php:91)
  at Illuminate\View\View->render()
     (/var/www/dealsbarter2/storage/framework/views/acc66827d67507316afea850c2260a930f02b3c8.php:81)
  at require('/var/www/dealsbarter2/storage/framework/views/acc66827d67507316afea850c2260a930f02b3c8.php')
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Filesystem/Filesystem.php:107)
  at Illuminate\Filesystem\Filesystem::Illuminate\Filesystem\{closure}()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Filesystem/Filesystem.php:108)
  at Illuminate\Filesystem\Filesystem->getRequire()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/Engines/PhpEngine.php:58)
  at Illuminate\View\Engines\PhpEngine->evaluatePath()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/Engines/CompilerEngine.php:61)
  at Illuminate\View\Engines\CompilerEngine->get()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/View.php:139)
  at Illuminate\View\View->getContents()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/View.php:122)
  at Illuminate\View\View->renderContents()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/View.php:91)
  at Illuminate\View\View->render()
     (/var/www/dealsbarter2/storage/framework/views/08609d43a0e87c7fc29e8d33b7637a61f3b5a0f1.php:711)
  at require('/var/www/dealsbarter2/storage/framework/views/08609d43a0e87c7fc29e8d33b7637a61f3b5a0f1.php')
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Filesystem/Filesystem.php:107)
  at Illuminate\Filesystem\Filesystem::Illuminate\Filesystem\{closure}()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Filesystem/Filesystem.php:108)
  at Illuminate\Filesystem\Filesystem->getRequire()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/Engines/PhpEngine.php:58)
  at Illuminate\View\Engines\PhpEngine->evaluatePath()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/Engines/CompilerEngine.php:61)
  at Illuminate\View\Engines\CompilerEngine->get()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/View.php:139)
  at Illuminate\View\View->getContents()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/View.php:122)
  at Illuminate\View\View->renderContents()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/View/View.php:91)
  at Illuminate\View\View->render()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Http/Response.php:69)
  at Illuminate\Http\Response->setContent()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Http/Response.php:35)
  at Illuminate\Http\Response->__construct()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Routing/ResponseFactory.php:55)
  at Illuminate\Routing\ResponseFactory->make()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Routing/ResponseFactory.php:85)
  at Illuminate\Routing\ResponseFactory->view()
     (/var/www/dealsbarter2/app/Exceptions/Handler.php:55)
  at App\Exceptions\Handler->render()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php:51)
  at Illuminate\Routing\Pipeline->handleException()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:130)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/app/Http/Middleware/RedirectIfMatched.php:29)
  at App\Http\Middleware\RedirectIfMatched->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TransformsRequest.php:21)
  at Illuminate\Foundation\Http\Middleware\TransformsRequest->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/ConvertEmptyStringsToNull.php:31)
  at Illuminate\Foundation\Http\Middleware\ConvertEmptyStringsToNull->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TransformsRequest.php:21)
  at Illuminate\Foundation\Http\Middleware\TransformsRequest->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TrimStrings.php:40)
  at Illuminate\Foundation\Http\Middleware\TrimStrings->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/ValidatePostSize.php:27)
  at Illuminate\Foundation\Http\Middleware\ValidatePostSize->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/PreventRequestsDuringMaintenance.php:86)
  at Illuminate\Foundation\Http\Middleware\PreventRequestsDuringMaintenance->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/vendor/fruitcake/laravel-cors/src/HandleCors.php:38)
  at Fruitcake\Cors\HandleCors->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Http/Middleware/TrustProxies.php:39)
  at Illuminate\Http\Middleware\TrustProxies->handle()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:167)
  at Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php:103)
  at Illuminate\Pipeline\Pipeline->then()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php:142)
  at Illuminate\Foundation\Http\Kernel->sendRequestThroughRouter()
     (/var/www/dealsbarter2/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php:111)
  at Illuminate\Foundation\Http\Kernel->handle()
     (/var/www/dealsbarter2/public/index.php:51)