Bugzilla – Attachment 164066 Details for
Bug 36418
Set response's content-type to application/json when needed - svc scripts
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 36418: Catch more cases where header respose should be application/json
Bug-36418-Catch-more-cases-where-header-respose-sh.patch (text/plain), 1.29 KB, created by
Lucas Gass (lukeg)
on 2024-03-28 15:15:22 UTC
(
hide
)
Description:
Bug 36418: Catch more cases where header respose should be application/json
Filename:
MIME Type:
Creator:
Lucas Gass (lukeg)
Created:
2024-03-28 15:15:22 UTC
Size:
1.29 KB
patch
obsolete
>From 643f2b80cdf1360ef63a8e7029a7cc912f1fa5d6 Mon Sep 17 00:00:00 2001 >From: Lucas Gass <lucas@bywatersolutions.com> >Date: Thu, 28 Mar 2024 15:13:59 +0000 >Subject: [PATCH] Bug 36418: Catch more cases where header respose should be > application/json > >--- > svc/mana/increment | 2 +- > svc/recall | 2 +- > 2 files changed, 2 insertions(+), 2 deletions(-) > >diff --git a/svc/mana/increment b/svc/mana/increment >index 684148379e..ed7d401f2d 100755 >--- a/svc/mana/increment >+++ b/svc/mana/increment >@@ -29,7 +29,7 @@ use JSON; > > my $input = CGI->new; > binmode STDOUT, ":encoding(UTF-8)"; >-print $input->header( -type => 'text/plain', -charset => 'UTF-8' ); >+print $input->header( -type => 'application/json', -charset => 'UTF-8' ); > > my ( $auth_status ) = > check_cookie_auth( $input->cookie('CGISESSID'), >diff --git a/svc/recall b/svc/recall >index 75eb2d39bd..02e2d8fa4b 100755 >--- a/svc/recall >+++ b/svc/recall >@@ -33,7 +33,7 @@ my $json = encode_json({ success => 0 }); > my ( $auth_status, $sessionID ) = check_cookie_auth( $input->cookie('CGISESSID'), { recall => 'manage_recalls' } ); > > if ( $auth_status ne "ok" ) { >- print $input->header(-type => 'text/plain', -status => '403 Forbidden'); >+ print $input->header(-type => 'application/json', -status => '403 Forbidden'); > exit 0; > } > >-- >2.30.2
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 36418
:
163837
|
163885
|
163922
|
163923
|
164066
|
164094
|
164095
|
164096
|
164097
|
164102
|
164103
|
164104
|
164105