$72 GRAYBYTE WORDPRESS FILE MANAGER $93

SERVER : premium201.web-hosting.com #1 SMP Wed Mar 26 12:08:09 UTC 2025
SERVER IP : 104.21.43.35 | ADMIN IP 216.73.216.180
OPTIONS : CRL = ON | WGT = ON | SDO = OFF | PKEX = OFF
DEACTIVATED : mail

/home/bravrvjk/hpgt.org/wp-content/plugins/elementor/modules/cloud-kit-library/data/

HOME
Current File : /home/bravrvjk/hpgt.org/wp-content/plugins/elementor/modules/cloud-kit-library/data//controller.php
<?php
namespace Elementor\Modules\CloudKitLibrary\Data;

use Elementor\Modules\CloudKitLibrary\Connect\Cloud_Kits;
use Elementor\Modules\CloudKitLibrary\Module as CloudKitLibrary;
use Elementor\App\Modules\KitLibrary\Data\Base_Controller;
use Elementor\Core\Utils\Collection;

if ( ! defined( 'ABSPATH' ) ) {
	exit; // Exit if accessed directly.
}

class Controller extends Base_Controller {

	public function get_name() {
		return 'cloud-kits';
	}

	public function get_items( $request ) {
		$data = $this->get_app()->get_all();

		if ( is_wp_error( $data ) ) {
			return [
				'data' => [],
			];
		}

		$kits = ( new Collection( $data ) )->map( function ( $kit ) {
			return [
				'id' => $kit['id'],
				'title' => $kit['title'],
				'thumbnail_url' => $kit['thumbnailUrl'],
				'created_at' => $kit['createdAt'],
				'updated_at' => $kit['updatedAt'],
				'status' => isset( $kit['status'] ) ? $kit['status'] : 'active',
			];
		} );

		return [
			'data' => $kits->values(),
		];
	}

	public function delete_item( $request ) {
		return [
			'data' => $this->get_app()->delete_kit( $request->get_param( 'id' ) ),
		];
	}

	public function get_item( $request ) {
		return [
			'data' => $this->get_app()->get_kit( [ 'id' => $request->get_param( 'id' ) ] ),
		];
	}

	public function register_endpoints() {
		$this->index_endpoint->register_item_route( \WP_REST_Server::DELETABLE, [
			'id' => [
				'description' => 'Unique identifier for the object.',
				'type' => 'integer',
				'required' => true,
			],
		] );

		$this->register_endpoint( new Endpoints\Eligibility( $this ) );
		$this->register_endpoint( new Endpoints\Quota( $this ) );
	}

	public function get_permission_callback( $request ) {
		return current_user_can( 'manage_options' );
	}

	protected function get_app(): Cloud_Kits {
		return CloudKitLibrary::get_app();
	}
}


Current_dir [ WRITEABLE ] Document_root [ WRITEABLE ]


[ Back ]
NAME
SIZE
LAST TOUCH
USER
CAN-I?
FUNCTIONS
..
--
4 Apr 2026 1.57 AM
bravrvjk / bravrvjk
0755
endpoints
--
4 Apr 2026 1.57 AM
bravrvjk / bravrvjk
0755
controller.php
1.799 KB
27 Oct 2025 2.18 PM
bravrvjk / bravrvjk
0644

GRAYBYTE WORDPRESS FILE MANAGER @ 2025 CONTACT ME
Static GIF