#2893 closed enhancement (fixed)

Refactor redundant `?t=json` handling code

Reported by: exarkun Owned by: GitHub <noreply@…>
Priority: normal Milestone: undecided
Component: code-frontend-web Version: 1.12.1
Keywords: review-needed Cc:
Launchpad Bug:

Description

A number of web resources re-implement the logic to notice a request for json-format output and select a different renderer implementation.

Refactor this to reduce duplication. This refactoring will make the change to add a json format for the welcome page (2476) simpler.

Change History (3)

comment:1 Changed at 2017-07-25T15:21:42Z by exarkun

  • Keywords review-needed added

comment:3 Changed at 2017-07-27T19:22:24Z by GitHub <noreply@…>

  • Owner set to GitHub <noreply@…>
  • Resolution set to fixed
  • Status changed from new to closed

In 0d278e3/trunk:

Merge PR429: refactor response format selection logic

Factor out the logic for detecting a query argument in an HTTP request
selecting an alternate response format. Use the resulting helper
throughout to reduce duplication for this feature.

Closes ticket:2893

Note: See TracTickets for help on using tickets.