mirror of
https://github.com/scm-manager/scm-manager.git
synced 2025-11-01 02:55:56 +01:00
Fix HalRepresentationWithEmbedded type (#1793)
Fix HalRepresentationWithEmbedded type since _embedded can be null. Co-authored-by: Sebastian Sdorra <sebastian.sdorra@cloudogu.com>
This commit is contained in:
@@ -51,7 +51,7 @@ const CloneInformation: FC<Props> = ({ url, repository }) => {
|
||||
|
||||
const error = changesetsError || defaultBranchError;
|
||||
const branch = defaultBranchData?.defaultBranch;
|
||||
const emptyRepository = changesets?._embedded.changesets.length === 0;
|
||||
const emptyRepository = (changesets?._embedded?.changesets.length || 0) === 0;
|
||||
|
||||
return (
|
||||
<div className="content">
|
||||
|
||||
Reference in New Issue
Block a user