Skip to content

Commit 58ba86f

Browse files
committed
fix: lint
1 parent 4d6fa4a commit 58ba86f

4 files changed

Lines changed: 7 additions & 8 deletions

File tree

src/taxonomy/tag-list/UsageCountDisplay.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ import type { Row } from '@tanstack/react-table';
55
import type {
66
TreeRowData,
77
} from '@src/taxonomy/tree-table/types';
8-
import type { TagListRowData } from './types';
98
import { getTagListRowData } from './utils';
109

1110
const UsageCountDisplay = ({ row }: { row: Row<TreeRowData>; }) => {

src/taxonomy/tag-list/hooks.ts

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -176,9 +176,11 @@ const useEditActions = ({
176176

177177
const getAxiosErrorMessage = (axiosError: AxiosError) => {
178178
const responseData = axiosError.response?.data;
179-
const tagError = responseData ? Object.entries(responseData)?.find((errItem: [string, unknown]) => (
180-
['tag', 'value', 'updated_tag_value'].includes(errItem[0].toLowerCase())
181-
)) : null;
179+
const tagError = responseData ?
180+
Object.entries(responseData)?.find((errItem: [string, unknown]) => (
181+
['tag', 'value', 'updated_tag_value'].includes(errItem[0].toLowerCase())
182+
)) :
183+
null;
182184

183185
const errorMessages = tagError ? tagError[1] : (
184186
axiosError.message || intl.formatMessage(globalMessages.unknownError)

src/taxonomy/tag-list/utils.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import { TagListRowData } from './types';
66
*
77
* Minimal getter function for `row.original`. Mainly because the naming of `original` is not expressive,
88
* and it needs to be cast to the correct type.
9-
*/
9+
*/
1010
export const getTagListRowData = (row: Row<TreeRowData>): TagListRowData => (
1111
row.original as unknown as TagListRowData
1212
);

src/taxonomy/tree-table/DraftRow.tsx

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -86,9 +86,7 @@ const DraftRow: React.FC<DraftRowProps> = ({
8686
<td aria-label="Usage Count">
8787
{row ? <UsageCountDisplay row={row} /> : null}
8888
</td>
89-
<td
90-
className="tree-table-create-row-actions-cell p-2"
91-
>
89+
<td className="tree-table-create-row-actions-cell p-2">
9290
<span className="d-flex justify-content-end">
9391
<span className="mr-2">
9492
<Button

0 commit comments

Comments
 (0)