added error handler
This commit is contained in:
@@ -32,6 +32,13 @@ class TeamStoreController extends Controller
|
||||
$UserModel = new UserModel;
|
||||
|
||||
$store_array = $m->selectTeamStore('StoreUrl', $teamStoreURL);
|
||||
|
||||
if(count($store_array) <= 0) {
|
||||
return view('merchbay.not_found')
|
||||
->with('message', "Store not found");
|
||||
}
|
||||
|
||||
|
||||
// $product_array = $m->selectTeamStoreProducts('TeamStoreId', $store_array[0]->Id);
|
||||
|
||||
$q = $request->input('q');
|
||||
@@ -252,6 +259,11 @@ class TeamStoreController extends Controller
|
||||
$store_array = $m->selectTeamStore('StoreUrl', $teamStoreURL);
|
||||
$product_array = $m->selectTeamStoreProducts('ProductURL', $productURL);
|
||||
|
||||
if(count($product_array) <= 0) {
|
||||
return view('merchbay.not_found')
|
||||
->with('message', "Store product not found");
|
||||
}
|
||||
|
||||
$thumbnails_array = $m->getThumbnails($product_array[0]->Id);
|
||||
$teams_array = $m->getTeams($product_array[0]->Id);
|
||||
$selectRoster = $m->selectRoster($product_array[0]->Id);
|
||||
|
||||
Reference in New Issue
Block a user