From 8738fd5ad75ca07fd5957948a3347ced162e37d3 Mon Sep 17 00:00:00 2001 From: Guoying Qi Date: Tue, 24 Sep 2024 16:15:17 +0100 Subject: [PATCH] update all other github request header check to regex match --- public_html/launch.php | 2 +- public_html/pipeline_health.php | 8 ++++---- update_issue_stats.php | 4 ++-- update_module_details.php | 2 +- update_pipeline_details.php | 2 +- update_stats.php | 26 +++++++++++++------------- 6 files changed, 22 insertions(+), 22 deletions(-) diff --git a/public_html/launch.php b/public_html/launch.php index bae5c79a99..50704d3c70 100644 --- a/public_html/launch.php +++ b/public_html/launch.php @@ -106,7 +106,7 @@ function launch_pipeline_web($pipeline, $release) { $gh_launch_schema_url = "https://api.github.com/repos/sanger-tol/{$pipeline}/contents/nextflow_schema.json?ref={$gh_launch_schema_url}"; $gh_launch_schema_json = file_get_contents($gh_launch_schema_url, false, $api_opts); - if (strpos($http_response_header[0], 'HTTP/1.1 200') === false) { + if (preg_match('/HTTP\/\d\.*\d* 200/', $http_response_header[0]) === false) { # Remember for next time file_put_contents($gh_pipeline_no_schema_fn, ''); echo '