Skip to content

Commit 96fc912

Browse files
committed
fix deprecation warning on PHP 8.5
curl_close is a NOP on PHP 8.0 and newer
1 parent 1bb68a1 commit 96fc912

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

DiscordWebhooks/Client.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,8 @@ protected function executeRequest($url, $postFields, $headers)
118118
throw new \Exception($httpcode . ':' . $result);
119119
}
120120

121+
if (PHP_VERSION_ID < 80000) {
121122
curl_close($ch);
122-
return $this;
123+
}
123124
}
124125
}

LICENSE.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
MIT License
22

3-
Copyright (c) 2017 Kyle Thompson
3+
Copyright (c) 2017-2026 Kyle Thompson
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal

0 commit comments

Comments
 (0)