HEX
Server: Apache/2.4.41 (Ubuntu)
System: Linux vm8 5.4.0-216-generic #236-Ubuntu SMP Fri Apr 11 19:53:21 UTC 2025 x86_64
User: afleverb (1000)
PHP: 7.4.33
Disabled: pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare,
Upload Files
File: //var/www/mussarq_bak/wp-content/themes/wpnull24/functions/migrations/us_migration_4_5.php
<?php

class us_migration_4_5 extends US_Migration_Translator {

	// Options
	public function translate_theme_options( &$options ) {
		$changed = FALSE;

		if ( isset( $options['preloader'] ) AND $options['preloader'] == 2 ) {
			$options['preloader'] = 1;
			$changed = TRUE;
		}

		if ( ! empty( $options['heading_font_family'] ) ) {
			$result_variant = 0;
			$font = explode( '|', $options['heading_font_family'], 2 );
			if ( ! empty( $font[1] ) ) {
				$selected_font_variants = explode( ',', $font[1] );
				if ( is_array( $selected_font_variants ) ) {
					foreach ( $selected_font_variants as $variant ) {
						if ( strpos( $variant, 'italic' ) === FALSE AND ( $result_variant == 0 OR $result_variant > $variant ) ) {
							$result_variant = $variant;
						}
					}
				}
			}
			if ( $result_variant != 0 ) {
				$options['h1_fontweight'] = $result_variant;
				$options['h2_fontweight'] = $result_variant;
				$options['h3_fontweight'] = $result_variant;
				$options['h4_fontweight'] = $result_variant;
				$options['h5_fontweight'] = $result_variant;
				$options['h6_fontweight'] = $result_variant;
				$changed = TRUE;
			}
		}

		return $changed;
	}

}