PluginProbe
Yatra – Travel Booking & Tour Operator Software / 3.0.16
Yatra – Travel Booking & Tour Operator Software v3.0.16
3.0.16 3.0.15 3.0.14 3.0.14.1 3.0.14.2 3.0.12 3.0.13 3.0.11 3.0.10 3.0.9 3.0.8 3.0.7 3.0.6 3.0.5 3.0.5.1 3.0.4 3.0.3 3.0.2.9 3.0.2.7 3.0.2.8 3.0.2.6 trunk 1.0.0 2.0.0 2.0.1 All 84 releases
← All changes | app/Ajax/DestinationShortcodeAjax.php +2 -8 3.0.2.7 → 3.0.16 View file →
@@ -22,11 +22,9 @@
22 22 {
23 23
24 24 // Verify nonce
25 25 if (!wp_verify_nonce($_POST['nonce'] ?? '', 'yatra_destination_shortcode_nonce')) {
26 - if (defined('WP_DEBUG') && WP_DEBUG) {
27 - error_log('Yatra Destination AJAX - Security check failed');
28 - }
26 +
29 27 wp_die(esc_html__('Security check failed', 'yatra'), '', ['response' => 403]);
30 28 }
31 29
32 30 // Parse shortcode attributes
@@ -77,13 +75,9 @@
77 75 'total_found' => $destinations_data['total_found'] ?? 0
78 76 ]);
79 77
80 78 } catch (\Exception $e) {
81 - // Log error for debugging
82 - if (defined('WP_DEBUG') && WP_DEBUG) {
83 - error_log('Yatra DestinationShortcode AJAX Error: ' . $e->getMessage());
84 - error_log('Yatra DestinationShortcode AJAX Trace: ' . $e->getTraceAsString());
85 - }
79 +
86 80
87 81 wp_send_json_error([
88 82 'message' => (defined('WP_DEBUG') && WP_DEBUG)
89 83 ? 'Error loading destinations: ' . $e->getMessage()