fix: resolve TypeScript build errors preventing Coolify deploy

- Fix nullable location in my-jobs search filter (job.location ?? '')
- Fix Locale type assertion in jobs/new description language select
- Fix nullable location in api.ts transformApiJobToFrontend

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Tiago Yamamoto 2026-02-18 11:33:45 -06:00
parent 9fd5cf5895
commit de3f497223
3 changed files with 3 additions and 3 deletions

View file

@ -111,7 +111,7 @@ export default function MyJobsPage() {
const matchesStatus = statusFilter === "all" || job.status === statusFilter
const matchesSearch =
job.title.toLowerCase().includes(searchTerm.toLowerCase()) ||
job.location.toLowerCase().includes(searchTerm.toLowerCase())
(job.location ?? '').toLowerCase().includes(searchTerm.toLowerCase())
return matchesStatus && matchesSearch
})

View file

@ -1147,7 +1147,7 @@ export default function PostJobPage() {
value={job.descriptionLanguage}
onChange={(e) => {
setDescriptionLanguageTouched(true);
setJob({ ...job, descriptionLanguage: e.target.value });
setJob({ ...job, descriptionLanguage: e.target.value as typeof job.descriptionLanguage });
}}
>
<option value="">{c.selectPlaceholder}</option>

View file

@ -612,7 +612,7 @@ export function transformApiJobToFrontend(apiJob: ApiJob): Job {
id: apiJob.id,
title: apiJob.title,
company: apiJob.companyName || "Unknown Company",
location: apiJob.location,
location: apiJob.location ?? '',
type: (apiJob.type as any) || "full-time",
workMode: (apiJob.workMode as any) || "onsite",
salary: salaryLabel,