* @copyright Since 2007 PrestaShop SA and Contributors * @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0) */ namespace PrestaShop\PrestaShop\Adapter\Notification\CommandHandler; use Notification; use PrestaShop\PrestaShop\Core\Domain\Notification\Command\UpdateEmployeeNotificationLastElementCommand; use PrestaShop\PrestaShop\Core\Domain\Notification\CommandHandler\UpdateEmployeeNotificationLastElementCommandHandlerInterface; /** * Handle update employee's last notification element of a given type * * @internal */ final class UpdateEmployeeNotificationLastElementHandler implements UpdateEmployeeNotificationLastElementCommandHandlerInterface { /** * @param UpdateEmployeeNotificationLastElementCommand $command */ public function handle(UpdateEmployeeNotificationLastElementCommand $command) { (new Notification())->updateEmployeeLastElement($command->getType()->getValue()); } }