code: public function unserialize($serialized)
      {
          $this->points = unserialize($serialized);
          if (!is_array($this->points)) {
              throw new InvalidDataException('The provided serialized data are invalid!');
          }
      }
docs: Constructs the object
  @link http://php.net/manual/en/serializable.unserialize.php
  @param string $serialized <p>
  The string representation of the object.
  </p>
  @return void
  @since 5.1.0
  @throws InvalidDataException