<?php

namespace App\Helpers;

use App\Models\TicketCommentModel;

class TicketCommentMapper
{
  public static function map(array $row): TicketCommentModel
  {
    return new TicketCommentModel(
      $row['id_komentar'],
      $row['id_ticket'],
      $row['id_user'],
      $row['komentar'],
      $row['tipe'],
      $row['tanggal_komentar'],
      $row['nama'] ?? null,
    );
  }
}
