Skip to content

Commit 704cc06

Browse files
118944: Fix hasDraftVersion$ not working for embedded payloads with no content
1 parent adb2e31 commit 704cc06

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/app/core/data/version-history-data.service.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@ export class VersionHistoryDataService extends IdentifiableDataService<VersionHi
171171
return this.versionDataService.findByHref(versionHref, false, true, followLink('versionhistory')).pipe(
172172
getFirstCompletedRemoteData(),
173173
switchMap((versionRD: RemoteData<Version>) => {
174-
if (versionRD.hasSucceeded && !versionRD.hasNoContent) {
174+
if (versionRD.hasSucceeded && !versionRD.hasNoContent && hasValue(versionRD.payload)) {
175175
return versionRD.payload.versionhistory.pipe(
176176
getFirstCompletedRemoteData(),
177177
map((versionHistoryRD: RemoteData<VersionHistory>) => {

0 commit comments

Comments
 (0)