summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/helper.php5
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/helper.php b/lib/helper.php
index debfb06..a81eedf 100644
--- a/lib/helper.php
+++ b/lib/helper.php
@@ -89,9 +89,8 @@ function git_url($repository,$type,$commit,$path,$line = null,$commit_is_hash =
$git_available = apcu_fetch('git_available', $apcu_success);
if ($apcu_success == false) {
$git_available =
- preg_match(
- "/ 200 OK$/",
- get_headers("https://git.archlinux32.org/packages")[0]
+ site_is_reachable(
+ 'https://git.archlinux32.org/packages'
);
apcu_store('git_available', $git_available, 120);
};