File tree Expand file tree Collapse file tree 2 files changed +3
-2
lines changed Expand file tree Collapse file tree 2 files changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -579,12 +579,13 @@ export function serverAudits(opts: ServerAuditOptions): Audit[] {
579
579
) ,
580
580
audit (
581
581
'BCF8' ,
582
- 'MAY use 400 status code on JSON parsing failure' ,
582
+ 'SHOULD use 400 status code on JSON parsing failure when accepting application/json ' ,
583
583
async ( ) => {
584
584
const res = await fetchFn ( await getUrl ( opts . url ) , {
585
585
method : 'POST' ,
586
586
headers : {
587
587
'content-type' : 'application/json' ,
588
+ accept : 'application/json' ,
588
589
} ,
589
590
body : '{ "not a JSON' ,
590
591
} ) ;
Original file line number Diff line number Diff line change @@ -192,7 +192,7 @@ exports[`should not change globally unique audit ids 1`] = `
192
192
} ,
193
193
{
194
194
" id" : " BCF8" ,
195
- " name" : " MAY use 400 status code on JSON parsing failure" ,
195
+ " name" : " SHOULD use 400 status code on JSON parsing failure when accepting application/json " ,
196
196
} ,
197
197
{
198
198
" id" : " 8764" ,
You can’t perform that action at this time.
0 commit comments