Skip to content

Commit

Permalink
[PUBLIC-36] Handle comment period instructions when no match exists (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
tolkamps1 authored Jan 10, 2025
1 parent 86427ec commit dbdc0be
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/app/project/commenting-tab/commenting-tab.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,8 @@ export class CommentingTabComponent implements OnInit, OnDestroy {
if (res.data) {
this.commentPeriods = res.data;
this.commentPeriods.forEach(element => {
element.instructions = element.instructions.match(/Comment Period on the (.*?) for /)[1];
const match = element.instructions.match(/Comment Period on the (.*?) for /);
element.instructions = match ? match[1] : '';
});
}
});
Expand Down

0 comments on commit dbdc0be

Please sign in to comment.