'integer', 'format_version' => 'integer', 'refers_to_sequence' => 'integer', 'payload' => 'array', ]; protected static function booted(): void { static::updating(fn () => throw new LogicException('Poll ledger entries cannot be changed.')); static::deleting(fn () => throw new LogicException('Poll ledger entries cannot be deleted.')); } public function poll() { return $this->belongsTo(Poll::class); } public function isBallot(): bool { return in_array($this->entry_type, [self::CAST, self::CHANGE], true); } }