diff --git a/types/error.go b/types/error.go index 7ef770ec..40d141cd 100644 --- a/types/error.go +++ b/types/error.go @@ -88,6 +88,13 @@ func (e *NewAPIError) GetErrorCode() ErrorCode { } func (e *NewAPIError) Error() string { + if e == nil { + return "" + } + if e.Err == nil { + // fallback message when underlying error is missing + return string(e.errorCode) + } return e.Err.Error() } diff --git a/web/src/components/table/ChannelsTable.js b/web/src/components/table/ChannelsTable.js index 19d759cd..3e089d6a 100644 --- a/web/src/components/table/ChannelsTable.js +++ b/web/src/components/table/ChannelsTable.js @@ -42,7 +42,7 @@ import { IconTreeTriangleDown, IconSearch, IconMore, - IconList, IconDescend2 + IconDescend2 } from '@douyinfe/semi-icons'; import { loadChannelModels, isMobile, copy } from '../../helpers'; import EditTagModal from '../../pages/Channel/EditTagModal.js'; @@ -630,7 +630,7 @@ const ChannelsTable = () => { > } /> diff --git a/web/src/components/table/LogsTable.js b/web/src/components/table/LogsTable.js index 1bf6934f..ad651331 100644 --- a/web/src/components/table/LogsTable.js +++ b/web/src/components/table/LogsTable.js @@ -410,7 +410,7 @@ const LogsTable = () => { return isAdminUser ? (