Expected default value to be empty string but found null #6762
Unanswered
ambianBeing314
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I have a test endpoint:
Its Implementation:
Calls:
http://localhost:8080/orders/test-default?test=sometext
Expected: test == sometext ✅
http://localhost:8080/orders/test-default
Expected or Assumed: test == "" ❌
According to @QueryValue the
defaultValue
defaults to""
empty string. So when printing the value of test the expectation was empty string but was insteadnull
. I could be missing something very obvious though.Beta Was this translation helpful? Give feedback.
All reactions