/** * Genera nuevo HASH para el evento * este hash permite acceder al mapa de forma publica * @return string */ protected function _nuevoHash() { $this->load->library("core/string/random"); $hash = $this->random->rand_string(45); $existe = $this->_emergencia_model->getByHash($hash); if (!is_null($existe)) { return $this->_nuevoHash(); } else { return $hash; } }