mirror of
https://github.com/cpvalente/ontime.git
synced 2026-08-08 08:53:51 +00:00
Revert "split url and searchParams allow for post option"
This reverts commit 54ab8d4ffe.
This commit is contained in:
@@ -227,15 +227,9 @@ export const parseOsc = (data: { osc?: Partial<OSCSettings> }): OSCSettings => {
|
||||
*/
|
||||
export const validateHttpSubscriptionCycle = (data: HttpSubscriptionOptions[]): boolean => {
|
||||
for (const subscriptionOption of data) {
|
||||
const isHttp = subscriptionOption.url?.startsWith('http://') || subscriptionOption.url?.startsWith('https://');
|
||||
const ishttpMethod = subscriptionOption.method == 'GET' || subscriptionOption.method == 'POST';
|
||||
if (
|
||||
typeof subscriptionOption.url !== 'string' ||
|
||||
typeof subscriptionOption.options !== 'string' ||
|
||||
!isHttp ||
|
||||
!ishttpMethod ||
|
||||
typeof subscriptionOption.enabled !== 'boolean'
|
||||
) {
|
||||
const isHttp =
|
||||
subscriptionOption.message?.startsWith('http://') || subscriptionOption.message?.startsWith('https://');
|
||||
if (typeof subscriptionOption.message !== 'string' || !isHttp || typeof subscriptionOption.enabled !== 'boolean') {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user