FHIR Chat · Requests for team feedback · ibm

Stream: ibm

Topic: Requests for team feedback


view this post on Zulip Lee Surprenant (Nov 06 2019 at 18:47):

we have 2 extremely similar error messages in SearchUtil for parse errors:

PARSE_PARAMETER_EXCEPTION = "An error occurred while parsing search parameter '%s'.";
PARSE_EXCEPTION = "Unable to parse search result parameter named: '%s";

view this post on Zulip Lee Surprenant (Nov 06 2019 at 18:47):

and two helpers that use them (respectively:

buildNewParseException
buildNewParseParameterException

view this post on Zulip Lee Surprenant (Nov 06 2019 at 18:48):

it seems like buildNewParseException is used for errors with "search result parameters" ( _summary, _page, _count, etc) whereas the other one is more generally for search parameters

view this post on Zulip Lee Surprenant (Nov 06 2019 at 18:48):

my question: is there any value in distinguishing these two cases from one another?

view this post on Zulip Lee Surprenant (Nov 06 2019 at 18:49):

any objection to me merging the two in my next PR?

view this post on Zulip Lee Surprenant (Nov 06 2019 at 19:12):

included it in https://github.com/IBM/FHIR/pull/369

view this post on Zulip Paul Bastide (Nov 06 2019 at 19:37):

The reasons they are there is exactly so the exceptions could be refactored

view this post on Zulip Paul Bastide (Nov 06 2019 at 19:37):

I saw the duplication, and put it in the same 'code' region

view this post on Zulip Paul Bastide (Nov 06 2019 at 19:37):

it's a good idea to refactor and simplify


Last updated: Apr 12 2022 at 19:14 UTC