From f823ac2fd8cf1c60713a6e9c811980daa60d30dc Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Wed, 16 Jun 2021 22:14:56 -0400 Subject: [PATCH] Syntax & regex updates --- cognito-forms-oembed.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/cognito-forms-oembed.php b/cognito-forms-oembed.php index 5584e14..9082ac4 100644 --- a/cognito-forms-oembed.php +++ b/cognito-forms-oembed.php @@ -40,9 +40,9 @@ if ( !class_exists('CognitoFormsOEmbed') ) { class CognitoFormsOEmbed { - public function __constructor() { - wp_oembed_add_provider( 'https://www.cognitoforms.com/*', 'https://www.cognitoforms.com/f/oembed/' ); + public function __construct() { + wp_oembed_add_provider( '#https?://(www\.)?cognitoforms\.com/.*#i', 'https://www.cognitoforms.com/f/oembed/', true ); } } - new CognitoFormsOEmbed + new CognitoFormsOEmbed; } \ No newline at end of file