Skip to content

Commit

Permalink
Ensure we don't crash if queryParams is null.
Browse files Browse the repository at this point in the history
  • Loading branch information
travist committed Jul 14, 2024
1 parent d713652 commit 6a0b2e4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion projects/angular-formio/resource/src/resource.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ export class FormioResourceService {
init(route: ActivatedRoute, router: Router = null) {
const snapshot = route.snapshot;
let reset = false;
if (snapshot.queryParams.hasOwnProperty('reset')) {
if (snapshot.queryParams?.hasOwnProperty('reset')) {
reset = snapshot.queryParams.reset;
}
else if (router) {
Expand Down

0 comments on commit 6a0b2e4

Please sign in to comment.