<?

namespace Shop\Concrete;

/**
 * методы получение корректного манагазина авторизованного пользователя
 *
 * @author Admin
 */
trait ShopAuthUserTrait
{

    /**
     *
     * @var \Shop\Models\Shop\Shop 
     */
    protected $curShop;

    public function setShopByAuthUserService(\Shop\Contracts\ShopByAuthUserInterface $shopService)
    {
        try {
            $this->curShop = $shopService->getShopByAuthUser();
        } catch (\Shop\Exceptions\ShopUserIsRoot $ex) {
            
        } catch (\Shop\Exceptions\ShopNotFound $ex){
            
        } catch (\Shop\Exceptions\NotAdminPath $ex){
            
        }
    }

}