<?php

use KupShop\KupShopBundle\Util\Compat\SymfonyBridge;

$acn = getVal('acn', null, 'add');
$IDp = getVal('IDp');

if ($acn == 'add') {
    SymfonyBridge::handleController('KupShop\CatalogBundle\Controller\FavoriteController::addAction', ['id' => $IDp]);
} elseif ($acn == 'delete') {
    SymfonyBridge::handleController('KupShop\CatalogBundle\Controller\FavoriteController::removeAction', ['id' => $IDp]);
} else {
    redirection('NEXT');
}
