Skip to content

Adding optional parameter support#1868

Merged
kshyju merged 6 commits intomainfrom
shkr/1651_nre_for_missing_param_value
Sep 8, 2023
Merged

Adding optional parameter support#1868
kshyju merged 6 commits intomainfrom
shkr/1651_nre_for_missing_param_value

Conversation

@kshyju
Copy link
Copy Markdown
Member

@kshyju kshyju commented Aug 29, 2023

Adding optional parameter support.

With this change, when a function has an optional parameter with a default value defined, and no corresponding input data is available for this parameter during invocation, we will use the default value of the parameter.

resolves #1651

  • My changes do not require documentation changes
    • Otherwise: Documentation issue linked to PR
  • My changes should not be added to the release notes for the next release
    • Otherwise: I've added my notes to release_notes.md
  • My changes do not need to be backported to a previous version
    • Otherwise: Backport tracked by issue/PR #issue_or_pr
  • I have added all required tests (Unit tests, E2E tests)

@kshyju kshyju changed the title Fallback to default value of parameter if provided Adding optional parameter support Aug 30, 2023
@kshyju kshyju marked this pull request as ready for review August 30, 2023 13:10
@kshyju kshyju force-pushed the shkr/1651_nre_for_missing_param_value branch from 06289ac to c4139b0 Compare August 31, 2023 15:20
Comment thread src/DotNetWorker.Core/Definition/FunctionParameter.cs Outdated
@kshyju kshyju force-pushed the shkr/1651_nre_for_missing_param_value branch from c4139b0 to dd40e28 Compare September 5, 2023 13:50
Comment thread src/DotNetWorker.Core/Context/Features/DefaultFunctionInputBindingFeature.cs Outdated
@kshyju kshyju merged commit 479fc30 into main Sep 8, 2023
@kshyju kshyju deleted the shkr/1651_nre_for_missing_param_value branch September 8, 2023 21:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

NullReferenceException thrown when query string value is missing

5 participants