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

Bumped maximum PHP version to 8.4 #2978

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ on:
branches: "*"
pull_request:
env:
php-version: 8.3
php-version: 8.4
cache-version: 1
jobs:
platform-check:
Expand Down Expand Up @@ -147,7 +147,7 @@ jobs:
needs: build
strategy:
matrix:
versions: [{php: "5.6", wordpress: "4.9"}, {php: "5.6", wordpress: "5.9"}, {php: "5.6", wordpress: "6.2"}, {php: "7.4", wordpress: "latest"}, {php: "8.3", wordpress: "latest"}]
versions: [{php: "5.6", wordpress: "4.9"}, {php: "5.6", wordpress: "5.9"}, {php: "5.6", wordpress: "6.2"}, {php: "7.4", wordpress: "latest"}, {php: "8.4", wordpress: "latest"}]
services:
mysql:
image: mysql:5
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ on:
tags:
- "*"
env:
php-version: 8.3
php-version: 8.4
cache-version: 1
jobs:
build:
Expand Down
1 change: 1 addition & 0 deletions phpcs.xml
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@
<exclude name="SlevomatCodingStandard.Arrays.DisallowPartiallyKeyed.DisallowedPartiallyKeyed"/>
<exclude name="SlevomatCodingStandard.Classes.RequireSingleLineMethodSignature.RequiredSingleLineSignature"/>
<exclude name="SlevomatCodingStandard.Classes.SuperfluousExceptionNaming.SuperfluousSuffix"/>
<exclude name="SlevomatCodingStandard.ControlStructures.LanguageConstructWithParentheses.UsedWithParentheses"/>
<exclude name="SlevomatCodingStandard.ControlStructures.NewWithoutParentheses.UselessParentheses"/>
<exclude name="SlevomatCodingStandard.Functions.RequireTrailingCommaInClosureUse.MissingTrailingComma"/>
<exclude name="SlevomatCodingStandard.Functions.RequireTrailingCommaInDeclaration.MissingTrailingComma"/>
Expand Down
12 changes: 6 additions & 6 deletions src/php/frontend/class-video-proxy.php
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@

if ( false === $transient ) {
http_response_code( 404 );
die;
exit();

Check warning on line 60 in src/php/frontend/class-video-proxy.php

View check run for this annotation

Codecov / codecov/patch

src/php/frontend/class-video-proxy.php#L60

Added line #L60 was not covered by tests
}

header( 'Accept-Ranges: bytes' );
Expand Down Expand Up @@ -87,7 +87,7 @@

if ( is_null( $stream ) ) {
http_response_code( 500 );
die;
exit();

Check warning on line 90 in src/php/frontend/class-video-proxy.php

View check run for this annotation

Codecov / codecov/patch

src/php/frontend/class-video-proxy.php#L90

Added line #L90 was not covered by tests
}

ob_end_clean();
Expand Down Expand Up @@ -116,7 +116,7 @@

if ( 2 !== count( $limits ) ) {
http_response_code( 416 );
die;
exit();

Check warning on line 119 in src/php/frontend/class-video-proxy.php

View check run for this annotation

Codecov / codecov/patch

src/php/frontend/class-video-proxy.php#L119

Added line #L119 was not covered by tests
}

$raw_start = $limits[0];
Expand All @@ -134,7 +134,7 @@

if ( $start > $end ) {
http_response_code( 416 );
die;
exit();

Check warning on line 137 in src/php/frontend/class-video-proxy.php

View check run for this annotation

Codecov / codecov/patch

src/php/frontend/class-video-proxy.php#L137

Added line #L137 was not covered by tests
}

return array( $start, $end );
Expand All @@ -152,15 +152,15 @@
private static function check_range_header( $header ) {
if ( ! str_starts_with( $header, 'bytes=' ) ) {
http_response_code( 416 );
die;
exit();

Check warning on line 155 in src/php/frontend/class-video-proxy.php

View check run for this annotation

Codecov / codecov/patch

src/php/frontend/class-video-proxy.php#L155

Added line #L155 was not covered by tests
}

$header = substr( $header, 6 );

// Multipart range requests are not supported.
if ( str_contains( $header, ',' ) ) {
http_response_code( 416 );
die;
exit();

Check warning on line 163 in src/php/frontend/class-video-proxy.php

View check run for this annotation

Codecov / codecov/patch

src/php/frontend/class-video-proxy.php#L163

Added line #L163 was not covered by tests
}

return $header;
Expand Down
Loading