Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactor status code handling: better logic split and an ability to override the code #52

Draft
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

rinatkhaziev
Copy link
Contributor

@rinatkhaziev rinatkhaziev commented Jul 30, 2024

This PR does two things:

  1. It moves all header manipulation into a send_headers callback, which seems to be more appropriate rather than stuffing in template_redirect
  2. Adds a new filter vip_maintenance_mode_origin_status_code. This is needed to disambiguate the user-triggered 503 coming from application with server-side generated 503.
  3. Set the code override to 566 in vipgo-helper.php

@GaryJones GaryJones force-pushed the update/custom-error-code branch from 197b7af to 5ac2c66 Compare November 23, 2024 16:28
@GaryJones
Copy link
Contributor

The CI checks are a bit of a false confidence here, as there is only one PHP test, and the PHPCS isn't run, but it's marked as passing now it has been rebased.

@GaryJones
Copy link
Contributor

@rinatkhaziev Is this still desired?

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.

2 participants