mirror of
https://github.com/nothingworksinc/ticketbeast.git
synced 2026-01-26 11:14:06 +00:00
72 - Extracting a Finder Method
This commit is contained in:
@@ -9,7 +9,7 @@ class OrdersController extends Controller
|
||||
{
|
||||
public function show($confirmationNumber)
|
||||
{
|
||||
$order = Order::where('confirmation_number', $confirmationNumber)->first();
|
||||
$order = Order::findByConfirmationNumber($confirmationNumber);
|
||||
return view('orders.show', ['order' => $order]);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user