PluginProbe
Timetics – Appointment Booking Calendar & Scheduling / 1.0.64
Timetics – Appointment Booking Calendar & Scheduling v1.0.64
1.0.64 1.0.62 1.0.63 1.0.61 1.0.60 1.0.59 1.0.58 1.0.57 1.0.56 trunk 1.0.0 1.0.1 1.0.10 1.0.11 1.0.12 1.0.13 1.0.14 1.0.15 1.0.16 1.0.17 1.0.18 1.0.19 1.0.2 1.0.20 1.0.21 All 65 releases
← All changes | core/services/api-service.php +7 -5 1.0.2 → 1.0.64 View file →
@@ -5,8 +5,10 @@
5 5 * @package Timetics
6 6 */
7 7 namespace Timetics\Core\Services;
8 8
9 +defined( 'ABSPATH' ) || exit;
10 +
9 11 use Timetics\Base\Api;
10 12 use Timetics\Utils\Singleton;
11 13 use WP_REST_Request;
12 14
@@ -147,9 +149,9 @@
147 149 $service = new Service( $service_id );
148 150
149 151 if ( ! $service->is_service() ) {
150 152 return [
151 - 'message' => __( 'Invalid service id.', 'timetics' ),
153 + 'message' => esc_html__( 'Invalid service id.', 'timetics' ),
152 154 'data' => [
153 155 'status' => 404,
154 156 ],
155 157 ];
@@ -170,9 +172,9 @@
170 172 $service = new Service( $service_id );
171 173
172 174 if ( ! $service->is_service() ) {
173 175 return [
174 - 'message' => __( 'Invalid service id.', 'timetics' ),
176 + 'message' => esc_html__( 'Invalid service id.', 'timetics' ),
175 177 'data' => [
176 178 'status' => 404,
177 179 ],
178 180 ];
@@ -198,9 +200,9 @@
198 200 $service = new Service( $service_id );
199 201
200 202 if ( ! $service->is_service() ) {
201 203 return [
202 - 'message' => __( 'Invalid service id.', 'timetics' ),
204 + 'message' => esc_html__( 'Invalid service id.', 'timetics' ),
203 205 'data' => [
204 206 'status' => 404,
205 207 ],
206 208 ];
@@ -208,9 +210,9 @@
208 210
209 211 $service->delete();
210 212
211 213 $response = [
212 - 'message' => __( 'Successfully deleted service', 'timetics' ),
214 + 'message' => esc_html__( 'Successfully deleted service', 'timetics' ),
213 215 'data' => [
214 216 'status' => 200,
215 217 ],
216 218 ];
@@ -283,9 +285,9 @@
283 285 $item = $this->prepare_item( $service );
284 286
285 287 $response = [
286 288 'success' => 1,
287 - 'message' => __( 'Succssfully created service', 'timetics' ),
289 + 'message' => esc_html__( 'Succssfully created service', 'timetics' ),
288 290 'data' => $item,
289 291 ];
290 292
291 293 return rest_ensure_response( $response );