Skip to content

Conversation

@kirre-bylund
Copy link
Contributor

@kirre-bylund kirre-bylund commented Nov 5, 2025

Build ability to pretty print json request and response bodies
Also re-add obfuscation that I'd accidentally disabled in my HTTP Queue refactor >.<

Copy link
Contributor

@JohannesLoot JohannesLoot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like you ❤️
Thank you :)
I approve!

@kirre-bylund kirre-bylund marked this pull request as ready for review November 6, 2025 11:25
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds functionality to pretty print JSON in request and response bodies for improved readability in logs, while also restoring log obfuscation that was previously disabled. The implementation provides a configurable option (prettifyJson) to format JSON with indentation when logging HTTP traffic.

Key changes:

  • Added prettifyJson configuration flag with corresponding UI controls
  • Implemented JSON prettification logic with fallback for both NewtonSoft.Json and alternative JSON libraries
  • Re-enabled log obfuscation in HTTP request/response logging and export functionality

Reviewed Changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
Runtime/Game/Resources/LootLockerConfig.cs Added prettifyJson config field and obfuscateLogs field, updated initialization methods
Runtime/Game/LootLockerLogger.cs Implemented obfuscation and prettification pipeline for logged JSON bodies
Runtime/Editor/ProjectSettings.cs Added UI control for the JSON prettification toggle
Runtime/Editor/LogViewer/LootLockerLogViewerUI.cs Updated log viewer to use obfuscation in exports and created JSON foldout UI component
Runtime/Client/LootLockerJson.cs Added PrettifyJsonString method for both JSON serialization backends

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@kirre-bylund kirre-bylund force-pushed the feat/pretty-print-json branch from 7242e25 to e7f67a2 Compare November 6, 2025 11:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants