public function emailExistsAction()
    {
        $email = $this->getEvent()->getRouteMatch()->getParam('email');
        $request = $this->getRequest();
        $response = $this->getResponse();

        $user = $this->getUserService()->getUserMapper()->findByEmail($email);
        if (empty($user)) {
            $result = ['result' => false];
        } else {
            $result = ['result' => true];
        }
        $response->setContent(\Zend\Json\Json::encode($result));

        return $response;
    }