File tree Expand file tree Collapse file tree 2 files changed +3
-1
lines changed Expand file tree Collapse file tree 2 files changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -7,6 +7,7 @@ Exclamation symbols (:exclamation:) note something of importance e.g. breaking c
77### Notes
88- [ :ledger : View file changes] [ Unreleased ]
99### Added
10+ - Allow webhook to contain custom query parameters.
1011### Changed
1112### Deprecated
1213### Removed
Original file line number Diff line number Diff line change @@ -236,7 +236,8 @@ public function validateAndSetWebhook(): self
236236 }
237237 return !empty ($ v );
238238 }, ARRAY_FILTER_USE_BOTH );
239- $ webhook ['url ' ] .= ( isset (parse_url ($ webhook ['url ' ])['query ' ])) ? '& ' : '? ' ;
239+
240+ $ webhook ['url ' ] .= parse_url ($ webhook ['url ' ], PHP_URL_QUERY ) === null ? '? ' : '& ' ;
240241 $ this ->handleOutput (
241242 $ this ->telegram ->setWebhook (
242243 $ webhook ['url ' ] . 'a=handle&s= ' . $ this ->params ->getBotParam ('secret ' ),
You can’t perform that action at this time.
0 commit comments