Plugin Directory

Changeset 3321428


Ignore:
Timestamp:
07/02/2025 06:55:04 PM (9 months ago)
Author:
openvideo
Message:

remove incorrect icon file, refresh channel path to check domain hosting status on settings page init

Location:
open-video
Files:
1 deleted
2 edited

Legend:

Unmodified
Added
Removed
  • open-video/trunk/OpenVideoNamespace/Channels.php

    r3320896 r3321428  
    258258                self::openvideoplugin_set_channel_path($new_channel_path);
    259259            }
     260            // if we have a channel path, it means the domain is verified
     261            update_option('openvideoplugin_domain_verification_status', array('verified' => true));
     262           
    260263            return true;
    261264        } catch (\Exception $e) {
  • open-video/trunk/OpenVideoNamespace/Settings.php

    r3320896 r3321428  
    9898        $status = get_option('openvideoplugin_domain_verification_status', false);
    9999        if (!$status || !isset($status['verified']) || !$status['verified']) {
    100             \add_settings_section(
    101                 'openvideoplugin_domain_verification_section',
    102                 __('Domain Verification', 'open-video'),
    103                 array(self::class, 'openvideoplugin_render_domain_verification_tab'),
    104                 'openvideoplugin_settings'
    105             );
     100            // refresh channel path to check if domain is verified
     101            OpenVideoPlugin_Channels::openvideoplugin_refresh_channel_path();
     102            // Re-check the status after refreshing
     103            $status = get_option('openvideoplugin_domain_verification_status', false);
     104
     105            if (!$status || !isset($status['verified']) || !$status['verified']) {
     106                \add_settings_section(
     107                    'openvideoplugin_domain_verification_section',
     108                    __('Domain Verification', 'open-video'),
     109                    array(self::class, 'openvideoplugin_render_domain_verification_tab'),
     110                    'openvideoplugin_settings'
     111                );
     112            }
    106113        }
    107114    }
Note: See TracChangeset for help on using the changeset viewer.