HEX
Server: Apache
System: Linux ecngx285.inmotionhosting.com 4.18.0-553.79.1.lve.el8.x86_64 #1 SMP Wed Oct 15 17:59:35 UTC 2025 x86_64
User: zeusxp5 (3862)
PHP: 8.3.28
Disabled: NONE
Upload Files
File: /home/zeusxp5/zenoxpressjobs.com/find-a-job.htm/wp-content/plugins/wp-social/app/route.php
<?php

namespace WP_Social\App;

use WP_Social\Base\Api;

class Route extends Api {

	public function config() {

		$this->prefix = 'settings';
		$this->param = "";
	}


	public function post_clear_counter_cache() {

		$data = $this->request->get_params();

		if(!empty($data['provider'])) {

			$provider = sanitize_key($data['provider']);
			$username = isset($data['username']) ? sanitize_key($data['username']) : '';

			if(delete_transient('_xs_social_' . $provider . '_count_' . $username)) {

				return [
					'success' => true,
					'msg'     => esc_html__('Cache cleared successfully!', 'wp-social')
				];
			}

			return [
				'success' => true,
				'msg'     => esc_html__('No cache found.', 'wp-social')
			];
		}

		return [
			'success' => true,
			'msg'     => esc_html__('Invalid data.', 'wp-social')
		];
	}
}