From 373f215ffa59eed3d28740517fd440ab124f0b8e Mon Sep 17 00:00:00 2001
From: Patrick Fic <>
Date: Thu, 11 Mar 2021 08:43:56 -0700
Subject: [PATCH] IO-749 Resolve error on displaying job with production note.
---
.../job-tombstone/job-tombstone.component.jsx | 16 +++++++++-------
1 file changed, 9 insertions(+), 7 deletions(-)
diff --git a/components/job-tombstone/job-tombstone.component.jsx b/components/job-tombstone/job-tombstone.component.jsx
index 8a33a71..b285e19 100644
--- a/components/job-tombstone/job-tombstone.component.jsx
+++ b/components/job-tombstone/job-tombstone.component.jsx
@@ -9,13 +9,13 @@ import {
Text,
} from "native-base";
import React from "react";
+import { useTranslation } from "react-i18next";
import { RefreshControl, StyleSheet } from "react-native";
import DataLabelComponent from "../data-label/data-label.component";
-import { useTranslation } from "react-i18next";
export default function JobTombstone({ job, loading, refetch }) {
const { t } = useTranslation();
- if (!!!job) {
+ if (!job) {
Job is not defined.
;
@@ -41,11 +41,13 @@ export default function JobTombstone({ job, loading, refetch }) {
{t("objects.jobs.labels.inproduction")}
)}
- {job.inproduction && job.production_vars && job.production_vars.note && (
-
- {job.production_vars.note}
-
- )}
+ {job.inproduction &&
+ job.production_vars &&
+ !!job.production_vars.note && (
+
+ {job.production_vars.note}
+
+ )}