Eliminada variable innecesaria
This commit is contained in:
parent
37cebf11ee
commit
0e8d179f6a
1 changed files with 1 additions and 2 deletions
|
@ -142,9 +142,8 @@ class SubpedidoController extends Controller
|
|||
$cantidad = $valid['cantidad'];
|
||||
if ($cantidad < 0) { // caso faltantes
|
||||
$barrio = GrupoDeCompra::find($subpedido->grupo_de_compra_id);
|
||||
$productosPedidos = $barrio->productosPedidos(true);
|
||||
|
||||
$productoPedido = $productosPedidos->where('producto_id', $producto->id)->first();
|
||||
$productoPedido = $barrio->productosPedidos()->where('producto_id', $producto->id)->first();
|
||||
if (!$productoPedido)
|
||||
abort(400, "No te puede faltar algo que no pediste.");
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue