HEX
Server: Apache/2.4.25
System: Linux ion14 4.9.0-8-amd64 #1 SMP Debian 4.9.144-3.1 (2019-02-19) x86_64
User: (10087)
PHP: 7.4.30
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,system, exec, shell_exec, passthru, popen, proc_open
Upload Files
File: /home/www/web115/wordpress/wp-content/themes/neve/header-footer-grid/Core/Settings/Defaults.php
<?php
/**
 * Defaults for HFG builder.
 *
 * @package     HFG
 * @copyright   Copyright (c) 2017, Marius Cristea
 * @license     http://opensource.org/licenses/gpl-2.0.php GNU Public License
 * @since       1.1.0
 */

namespace HFG\Core\Settings;

/**
 * Class Defaults
 *
 * @package HFG\Core\Settings
 */
class Defaults implements \ArrayAccess {

	/**
	 * Holds default schema used for migration purposes or smart defaults.
	 *
	 * @var array|mixed|void Schema array.
	 */
	public static $defaults_schema = [];

	/**
	 * Defaults constructor.
	 */
	public function __construct() {
		self::$defaults_schema = apply_filters( 'hfg_settings_schema', [] );
	}

	/**
	 * Check if we have the setting.
	 *
	 * @param mixed $offset Offset key.
	 *
	 * @return bool Is set?
	 */
	public function offsetExists( $offset ): bool {
		return isset( self::$defaults_schema[ $offset ] );
	}

	/**
	 * Return setting value.
	 *
	 * @param mixed $offset Offset id.
	 *
	 * @return mixed Value.
	 */
	#[\ReturnTypeWillChange]
	public function offsetGet( $offset ) {
		return self::$defaults_schema[ $offset ];
	}

	/**
	 * Set value.
	 *
	 * @param mixed $offset Default key.
	 * @param mixed $value Default value.
	 *
	 * @return void
	 */
	#[\ReturnTypeWillChange]
	public function offsetSet( $offset, $value ) {
		self::$defaults_schema[ $offset ] = $value;
	}

	/**
	 * Remove default from collection.
	 *
	 * @param mixed $offset Offset key.
	 *
	 * @return void
	 */
	#[\ReturnTypeWillChange]
	public function offsetUnset( $offset ) {
		unset( self::$defaults_schema[ $offset ] );
	}
}