/** * @return string */ public function getMasked() { if (strlen($this->value) === 11 && $this->value[0] != '0') { return parent::getMasked(); } if ($this->next != null) { return $this->next->getMasked(); } return $this->value; }
/** * @return string */ public function getMasked() { if (strlen($this->value) === 12 && $this->value[0] == '0') { $this->value = substr($this->value, 1, strlen($this->value)); return parent::getMasked(); } if ($this->next != null) { return $this->next->getMasked(); } return $this->value; }