Skip to content

Commit e59ea8e

Browse files
committed
cleanup(profiles): special case default handling of unrecognized query param vals
1 parent 90ed6d0 commit e59ea8e

File tree

1 file changed

+14
-9
lines changed

1 file changed

+14
-9
lines changed

_format/1.1/index.md

Lines changed: 14 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -2147,15 +2147,20 @@ when encountering unrecognized values.
21472147
If a profile does not define its own rules for handling unrecognized values,
21482148
the following rule applies by default:
21492149

2150-
1. If the unrecognized value is a JSON object, and the only thing that makes
2151-
it unrecognized is that it contains one or more keys that have no meaning
2152-
assigned to them (in the latest revision of the profile that the application
2153-
is aware of), then the application **MUST** simply ignore those unknown
2154-
keys and continue processing the profile.
2155-
2156-
2. However, in all other cases, the application **MUST** assume that the
2157-
profile has been applied erroneously and **MUST** totally ignore the
2158-
profile (i.e., process the document as if the profile were not there).
2150+
1. If the unrecognized value occurs is the value of a profile-defined query
2151+
parameter, the server **MUST** fail the request and respond with a
2152+
`400 Bad Request` and an [error object][error objects] indicating the
2153+
problematic parameter.
2154+
2155+
2. Otherwise, if the unrecognized value is a JSON object, and the only thing
2156+
that makes it unrecognized is that it contains one or more keys that have
2157+
no meaning assigned to them (in the latest revision of the profile that the
2158+
application is aware of), then the application **MUST** simply ignore those
2159+
unknown keys and continue processing the profile.
2160+
2161+
3. In all other cases, the application **MUST** assume that the profile has
2162+
been applied erroneously and **MUST** totally ignore the profile (i.e.,
2163+
process the document as if the profile were not there).
21592164

21602165
In the case of our example [timestamps profile], it does not define its own
21612166
rules, so the above defaults would apply.

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy