make(Illuminate\Contracts\Console\Kernel::class); $kernel->bootstrap(); try { $inquiry = ['name' => 'Test User', 'email' => 'test@example.com', 'phone' => '123456789', 'preferred_time' => 'Morning', 'message' => 'Hello']; $listing = App\Models\Listing::first(); $owner = App\Models\User::find($listing->user_id); Mail::to($owner->email)->send(new App\Mail\WalkThroughInquiryMail($inquiry, $listing, false)); echo "Mail test sent successfully to {$owner->email}\n"; } catch (\Exception $e) { echo "Error sending mail: " . $e->getMessage() . "\n"; }