X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=webrtc%2Fwebrtc.php;h=4ea17f471423dc6e25300862447735e8a3cade6e;hb=d9330e3b05c71bbd172293fb223271033d3b19f7;hp=8b3a243e32e49174dca797c13d0ca843b31d4df6;hpb=5c5c23acb062960dff33bf5fe86f32ff20515389;p=friendica-addons.git diff --git a/webrtc/webrtc.php b/webrtc/webrtc.php index 8b3a243e..4ea17f47 100644 --- a/webrtc/webrtc.php +++ b/webrtc/webrtc.php @@ -7,6 +7,8 @@ * Author: Tobias Diekershoff */ +use Friendica\Core\Config; + function webrtc_install() { register_hook('app_menu', 'addon/webrtc/webrtc.php', 'webrtc_app_menu'); } @@ -24,12 +26,12 @@ function webrtc_plugin_admin (&$a, &$o) { $t = get_markup_template( "admin.tpl", "addon/webrtc/" ); $o = replace_macros( $t, array( '$submit' => t('Save Settings'), - '$webrtcurl' => array('webrtcurl', t('WebRTC Base URL'), get_config('webrtc','webrtcurl' ), t('Page your users will create a WebRTC chat room on. For example you could use https://live.mayfirst.org .')), + '$webrtcurl' => array('webrtcurl', t('WebRTC Base URL'), Config::get('webrtc','webrtcurl' ), t('Page your users will create a WebRTC chat room on. For example you could use https://live.mayfirst.org .')), )); } function webrtc_plugin_admin_post (&$a) { $url = ((x($_POST, 'webrtcurl')) ? notags(trim($_POST['webrtcurl'])) : ''); - set_config('webrtc', 'webrtcurl', $url); + Config::set('webrtc', 'webrtcurl', $url); info( t('Settings updated.'). EOL); } @@ -41,7 +43,7 @@ function webrtc_content(&$a) { $o = ''; /* landingpage to create chatrooms */ - $webrtcurl = get_config('webrtc','webrtcurl'); + $webrtcurl = Config::get('webrtc','webrtcurl'); /* embedd the landing page in an iframe */ $o .= '

'.t('Video Chat').'

';