PluginProbe
Fluent Booking – The Ultimate Appointments Scheduling, Events Booking, Events Calendar Solution / 2.5.0
Fluent Booking – The Ultimate Appointments Scheduling, Events Booking, Events Calendar Solution v2.5.0
2.5.0 2.4.0 2.3.0 2.2.5 2.2.0 2.1.2 2.1.1 trunk 1.10.0 1.10.01 1.10.02 1.5.0 1.5.01 1.5.02 1.5.1 1.5.10 1.5.20 1.5.21 1.5.22 1.5.23 1.5.24 1.5.25 1.6.0 1.7.0 1.7.1 All 34 releases
← All changes | app/Services/Integrations/Elementor/ElementorIntegration.php +11 -2 2.1.2 → 2.5.0 View file →
@@ -99,16 +99,20 @@
99 99 wp_send_json_error(['message' => __('Nonce verification failed', 'fluent-booking')]);
100 100 exit;
101 101 }
102 102
103 + if (!current_user_can('edit_posts')) {
104 + wp_send_json_error(['message' => __('You do not have permission to perform this action', 'fluent-booking')]);
105 + exit;
106 + }
107 +
103 108 if (!isset($_POST['cal_id'])) {
104 109 wp_send_json_error(['message' => __('No calendar ID provided', 'fluent-booking')]);
105 110 }
106 111
107 112 $calId = intval($_POST['cal_id']);
108 - $events = []; // Fetch events using your getCalendarEvents method or similar
113 + $events = [];
109 114
110 - // Example of fetching events (you need to replace this with your actual method)
111 115 $events = $this->getCalendarEvents($calId);
112 116
113 117 wp_send_json_success($events);
114 118 }
@@ -115,8 +119,13 @@
115 119
116 120 public function ajaxGetEventHash() {
117 121 if (!isset($_POST['security']) || !wp_verify_nonce(sanitize_text_field(wp_unslash($_POST['security'])), 'calendar_events_nonce')) {
118 122 wp_send_json_error(['message' => __('Nonce verification failed', 'fluent-booking')]);
123 + exit;
124 + }
125 +
126 + if (!current_user_can('edit_posts')) {
127 + wp_send_json_error(['message' => __('You do not have permission to perform this action', 'fluent-booking')]);
119 128 exit;
120 129 }
121 130
122 131 $eventId = isset($_POST['event_id']) ? intval($_POST['event_id']) : null;