Skip to content

Commit c2266b1

Browse files
prevent error checking for latest when version can be null
TODO: This will all be typed once we migrate this component and its parent (Index.vue) to composition API and TS.
1 parent bc1db3f commit c2266b1

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

client/src/components/Workflow/Editor/WorkflowAttributes.vue

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -263,7 +263,11 @@ Acceptable format:
263263
computed: {
264264
/** Determines if the current version is not the latest */
265265
canSwitchToLatestVersion() {
266-
return this.versions?.length > 1 && this.version !== this.versions[this.versions.length - 1].version;
266+
return (
267+
this.versions?.length > 1 &&
268+
this.version !== null &&
269+
this.version !== this.versions[this.versions.length - 1].version
270+
);
267271
},
268272
creatorAsList() {
269273
let creator = this.creator;

0 commit comments

Comments
 (0)