summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJesse Plamondon-Willard <github@jplamondonw.com>2017-09-22 18:19:42 -0400
committerJesse Plamondon-Willard <github@jplamondonw.com>2017-09-22 18:19:42 -0400
commit5619890abf866e608e667bc6cd81b5aba9e3a350 (patch)
tree7ec7f710212f6d88a344280493dd11c5499552ab /src
parent86d4827df211cc28549acb88ee7cb08d6cc4d4aa (diff)
downloadSMAPI-5619890abf866e608e667bc6cd81b5aba9e3a350.tar.gz
SMAPI-5619890abf866e608e667bc6cd81b5aba9e3a350.tar.bz2
SMAPI-5619890abf866e608e667bc6cd81b5aba9e3a350.zip
indent JSON responses (#336)
Diffstat (limited to 'src')
-rw-r--r--src/StardewModdingAPI.Web/Startup.cs6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/StardewModdingAPI.Web/Startup.cs b/src/StardewModdingAPI.Web/Startup.cs
index abae06ec..b35d072b 100644
--- a/src/StardewModdingAPI.Web/Startup.cs
+++ b/src/StardewModdingAPI.Web/Startup.cs
@@ -38,7 +38,11 @@ namespace StardewModdingAPI.Web
{
services
.AddMvc()
- .AddJsonOptions(options => options.SerializerSettings.NullValueHandling = NullValueHandling.Ignore); // suppress null values in JSON responses
+ .AddJsonOptions(options =>
+ {
+ options.SerializerSettings.Formatting = Formatting.Indented;
+ options.SerializerSettings.NullValueHandling = NullValueHandling.Ignore;
+ });
}
/// <summary>The method called by the runtime to configure the HTTP request pipeline.</summary>