You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In my Application i am analyzing the provided Content-Type Header attribute during a multipart/form-data post request of the overall request and the different parts. At first i only looked up the Documentation from the website.
For LazyStringMapTemplate::get it states the return is "Get value as oatpp::String". This tempted my to use the empty function of strings to check if the key Content-Type exists.
I assumed if the key is not present an empty string is returned. The actual returned nullptr crashed the application if the field was not present.
Is it possible to either update the documentation to state that a nullptr is returned the key is not valid or to return an empty string instead of nullptr?
Hi all,
Thank you for your work on oatpp.
In my Application i am analyzing the provided Content-Type Header attribute during a multipart/form-data post request of the overall request and the different parts. At first i only looked up the Documentation from the website.
For
LazyStringMapTemplate::get
it states the return is "Get value asoatpp::String
". This tempted my to use the empty function of strings to check if the key Content-Type exists.I assumed if the key is not present an empty string is returned. The actual returned
nullptr
crashed the application if the field was not present.Is it possible to either update the documentation to state that a
nullptr
is returned the key is not valid or to return an empty string instead ofnullptr
?oatpp/src/oatpp/core/data/share/LazyStringMap.hpp
Lines 222 to 240 in 17ef2a7
The text was updated successfully, but these errors were encountered: