Completed
Branch BUG-9548-transaction-completio... (f1723a)
by
unknown
592:31 queued 571:19
created
core/db_classes/EE_Question_Group_Question.class.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -2,15 +2,15 @@  discard block
 block discarded – undo
2 2
 /**
3 3
  * Required  by EEM_Question_Group_Question in case someone queries for all its model objects
4 4
  */
5
-class EE_Question_Group_Question extends EE_Base_Class{
5
+class EE_Question_Group_Question extends EE_Base_Class {
6 6
 
7 7
 	/**
8 8
 	 * @param array $props_n_values
9 9
 	 * @return EE_Question_Group_Question|mixed
10 10
 	 */
11
-	public static function new_instance( $props_n_values = array() ) {
12
-		$has_object = parent::_check_for_object( $props_n_values, __CLASS__ );
13
-		return $has_object ? $has_object : new self( $props_n_values );
11
+	public static function new_instance($props_n_values = array()) {
12
+		$has_object = parent::_check_for_object($props_n_values, __CLASS__);
13
+		return $has_object ? $has_object : new self($props_n_values);
14 14
 	}
15 15
 
16 16
 
@@ -19,7 +19,7 @@  discard block
 block discarded – undo
19 19
 	 * @param array $props_n_values
20 20
 	 * @return EE_Question_Group_Question
21 21
 	 */
22
-	public static function new_instance_from_db ( $props_n_values = array() ) {
23
-		return new self( $props_n_values, TRUE );
22
+	public static function new_instance_from_db($props_n_values = array()) {
23
+		return new self($props_n_values, TRUE);
24 24
 	}
25 25
 }
26 26
\ No newline at end of file
Please login to merge, or discard this patch.
core/db_classes/EE_Registration.class.php 4 patches
Indentation   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -2,12 +2,12 @@  discard block
 block discarded – undo
2 2
 	exit( 'No direct script access allowed' );
3 3
 }
4 4
 /**
5
- * EE_Registration class
6
- *
7
- * @package 			Event Espresso
8
- * @subpackage 	includes/classes/EE_Registration.class.php
9
- * @author 				Mike Nelson, Brent Christensen
10
- */
5
+	 * EE_Registration class
6
+	 *
7
+	 * @package 			Event Espresso
8
+	 * @subpackage 	includes/classes/EE_Registration.class.php
9
+	 * @author 				Mike Nelson, Brent Christensen
10
+	 */
11 11
 class EE_Registration extends EE_Soft_Delete_Base_Class implements EEI_Registration {
12 12
 
13 13
 
@@ -636,9 +636,9 @@  discard block
 block discarded – undo
636 636
 
637 637
 
638 638
 	/**
639
-	*		get  Attendee Number
640
-	* 		@access		public
641
-	*/
639
+	 *		get  Attendee Number
640
+	 * 		@access		public
641
+	 */
642 642
 	public function count() {
643 643
 		return $this->get( 'REG_count' );
644 644
 	}
Please login to merge, or discard this patch.
Braces   +4 added lines, -3 removed lines patch added patch discarded remove patch
@@ -126,7 +126,7 @@  discard block
 block discarded – undo
126 126
 			parent::set( 'STS_ID', $new_STS_ID, $use_default );
127 127
 			do_action( 'AHEE__EE_Registration__set_status__after_update', $this );
128 128
 			return TRUE;
129
-		}else{
129
+		} else{
130 130
 			//even though the old value matches the new value, it's still good to
131 131
 			//allow the parent set method to have a say
132 132
 			parent::set( 'STS_ID', $new_STS_ID, $use_default );
@@ -625,8 +625,9 @@  discard block
 block discarded – undo
625 625
 	 * @return EE_Registration
626 626
 	 */
627 627
 	public function get_primary_registration()  {
628
-		if ( $this->is_primary_registrant() )
629
-			return $this;
628
+		if ( $this->is_primary_registrant() ) {
629
+					return $this;
630
+		}
630 631
 
631 632
 		//k reg_count !== 1 so let's get the EE_Registration object matching this txn_id and reg_count == 1
632 633
 		$primary_registrant = EEM_Registration::instance()->get_one( array( array('TXN_ID' => $this->transaction_ID(), 'REG_count' => 1 ) ) );
Please login to merge, or discard this patch.
Doc Comments   +4 added lines, -3 removed lines patch added patch discarded remove patch
@@ -802,7 +802,7 @@  discard block
 block discarded – undo
802 802
 	 * (either the question's ID or a question object)
803 803
 	 * @param EE_Question|int $question
804 804
 	 * @param bool            $pretty_value
805
-	 * @return array|string if pretty_value= true, the result will always be a string
805
+	 * @return string if pretty_value= true, the result will always be a string
806 806
 	 * (because the answer might be an array of answer values, so passing pretty_value=true
807 807
 	 * will convert it into some kind of string)
808 808
 	 */
@@ -901,7 +901,7 @@  discard block
 block discarded – undo
901 901
 	/**
902 902
 	 * Sets deleted
903 903
 	 * @param boolean $deleted
904
-	 * @return boolean
904
+	 * @return boolean|null
905 905
 	 */
906 906
 	public function set_deleted($deleted) {
907 907
 		$this->set( 'REG_deleted', $deleted );
@@ -945,6 +945,7 @@  discard block
 block discarded – undo
945 945
 	 *
946 946
 	 * @param int | EE_Datetime $DTT_OR_ID The datetime the registration is being checked against
947 947
 	 * @param bool   $check_approved   This is used to indicate whether the caller wants can_checkin to also consider registration status as well as datetime access.
948
+	 * @param integer $DTT_OR_ID
948 949
 	 *
949 950
 	 * @return bool
950 951
 	 */
@@ -1305,7 +1306,7 @@  discard block
 block discarded – undo
1305 1306
 	 * This grabs the payment method corresponding to the last payment made for the amount owing on the registration.
1306 1307
 	 * Note: if there are no payments on the registration there will be no payment method returned.
1307 1308
 	 *
1308
-	 * @return EE_Payment_Method|null
1309
+	 * @return EE_Base_Class|null
1309 1310
 	 */
1310 1311
 	public function payment_method() {
1311 1312
 		return EEM_Payment_Method::instance()->get_last_used_for_registration( $this );
Please login to merge, or discard this patch.
Spacing   +185 added lines, -185 removed lines patch added patch discarded remove patch
@@ -1,5 +1,5 @@  discard block
 block discarded – undo
1
-<?php if ( !defined( 'EVENT_ESPRESSO_VERSION' ) ) {
2
-	exit( 'No direct script access allowed' );
1
+<?php if ( ! defined('EVENT_ESPRESSO_VERSION')) {
2
+	exit('No direct script access allowed');
3 3
 }
4 4
 /**
5 5
  * EE_Registration class
@@ -41,9 +41,9 @@  discard block
 block discarded – undo
41 41
 	 *                             		    date_format and the second value is the time format
42 42
 	 * @return EE_Registration
43 43
 	 */
44
-	public static function new_instance( $props_n_values = array(), $timezone = null, $date_formats = array() ) {
45
-		$has_object = parent::_check_for_object( $props_n_values, __CLASS__, $timezone, $date_formats );
46
-		return $has_object ? $has_object : new self( $props_n_values, false, $timezone, $date_formats );
44
+	public static function new_instance($props_n_values = array(), $timezone = null, $date_formats = array()) {
45
+		$has_object = parent::_check_for_object($props_n_values, __CLASS__, $timezone, $date_formats);
46
+		return $has_object ? $has_object : new self($props_n_values, false, $timezone, $date_formats);
47 47
 	}
48 48
 
49 49
 
@@ -54,8 +54,8 @@  discard block
 block discarded – undo
54 54
 	 *                          		the website will be used.
55 55
 	 * @return EE_Registration
56 56
 	 */
57
-	public static function new_instance_from_db( $props_n_values = array(), $timezone = null ) {
58
-		return new self( $props_n_values, TRUE, $timezone );
57
+	public static function new_instance_from_db($props_n_values = array(), $timezone = null) {
58
+		return new self($props_n_values, TRUE, $timezone);
59 59
 	}
60 60
 
61 61
 
@@ -66,8 +66,8 @@  discard block
 block discarded – undo
66 66
 	 * @access        public
67 67
 	 * @param        int $EVT_ID Event ID
68 68
 	 */
69
-	public function set_event( $EVT_ID = 0 ) {
70
-		$this->set( 'EVT_ID', $EVT_ID );
69
+	public function set_event($EVT_ID = 0) {
70
+		$this->set('EVT_ID', $EVT_ID);
71 71
 	}
72 72
 
73 73
 
@@ -78,18 +78,18 @@  discard block
 block discarded – undo
78 78
 	 * @param mixed  $field_value
79 79
 	 * @param bool   $use_default
80 80
 	 */
81
-	public function set( $field_name, $field_value, $use_default = FALSE ) {
82
-		switch( $field_name ) {
81
+	public function set($field_name, $field_value, $use_default = FALSE) {
82
+		switch ($field_name) {
83 83
 			case 'REG_code' :
84
-				if ( ! empty( $field_value ) && $this->reg_code() == '' ) {
85
-					$this->set_reg_code( $field_value, $use_default );
84
+				if ( ! empty($field_value) && $this->reg_code() == '') {
85
+					$this->set_reg_code($field_value, $use_default);
86 86
 				}
87 87
 				break;
88 88
 			case 'STS_ID' :
89
-				$this->set_status( $field_value, $use_default );
89
+				$this->set_status($field_value, $use_default);
90 90
 				break;
91 91
 			default :
92
-				parent::set( $field_name, $field_value, $use_default );
92
+				parent::set($field_name, $field_value, $use_default);
93 93
 		}
94 94
 	}
95 95
 
@@ -106,30 +106,30 @@  discard block
 block discarded – undo
106 106
 	 * @param boolean $use_default
107 107
 	 * @return bool
108 108
 	 */
109
-	public function set_status( $new_STS_ID = NULL, $use_default = FALSE ) {
109
+	public function set_status($new_STS_ID = NULL, $use_default = FALSE) {
110 110
 		// get current REG_Status
111 111
 		$old_STS_ID = $this->status_ID();
112 112
 		// if status has changed
113
-		if ( $old_STS_ID != $new_STS_ID  ) {
113
+		if ($old_STS_ID != $new_STS_ID) {
114 114
 			// TO approved
115
-			if ( $new_STS_ID == EEM_Registration::status_id_approved ) {
115
+			if ($new_STS_ID == EEM_Registration::status_id_approved) {
116 116
 				// reserve a space by incrementing ticket and datetime sold values
117 117
 				$this->_reserve_registration_space();
118
-				do_action( 'AHEE__EE_Registration__set_status__to_approved', $this, $old_STS_ID, $new_STS_ID );
118
+				do_action('AHEE__EE_Registration__set_status__to_approved', $this, $old_STS_ID, $new_STS_ID);
119 119
 			// OR FROM  approved
120
-			} else if ( $old_STS_ID == EEM_Registration::status_id_approved ) {
120
+			} else if ($old_STS_ID == EEM_Registration::status_id_approved) {
121 121
 				// release a space by decrementing ticket and datetime sold values
122 122
 				$this->_release_registration_space();
123
-				do_action( 'AHEE__EE_Registration__set_status__from_approved', $this, $old_STS_ID, $new_STS_ID );
123
+				do_action('AHEE__EE_Registration__set_status__from_approved', $this, $old_STS_ID, $new_STS_ID);
124 124
 			}
125 125
 			// update status
126
-			parent::set( 'STS_ID', $new_STS_ID, $use_default );
127
-			do_action( 'AHEE__EE_Registration__set_status__after_update', $this );
126
+			parent::set('STS_ID', $new_STS_ID, $use_default);
127
+			do_action('AHEE__EE_Registration__set_status__after_update', $this);
128 128
 			return TRUE;
129
-		}else{
129
+		} else {
130 130
 			//even though the old value matches the new value, it's still good to
131 131
 			//allow the parent set method to have a say
132
-			parent::set( 'STS_ID', $new_STS_ID, $use_default );
132
+			parent::set('STS_ID', $new_STS_ID, $use_default);
133 133
 			return TRUE;
134 134
 		}
135 135
 	}
@@ -141,7 +141,7 @@  discard block
 block discarded – undo
141 141
 	 * @access        public
142 142
 	 */
143 143
 	public function status_ID() {
144
-		return $this->get( 'STS_ID' );
144
+		return $this->get('STS_ID');
145 145
 	}
146 146
 
147 147
 
@@ -166,12 +166,12 @@  discard block
 block discarded – undo
166 166
 	 * @param boolean $include_archived whether to include archived tickets or not.
167 167
 	 * @return EE_Ticket
168 168
 	 */
169
-	public function ticket( $include_archived = TRUE ) {
169
+	public function ticket($include_archived = TRUE) {
170 170
 		$query_params = array();
171
-		if ( $include_archived ) {
172
-			$query_params[ 'default_where_conditions' ] = 'none';
171
+		if ($include_archived) {
172
+			$query_params['default_where_conditions'] = 'none';
173 173
 		}
174
-		return $this->get_first_related( 'Ticket', $query_params );
174
+		return $this->get_first_related('Ticket', $query_params);
175 175
 	}
176 176
 
177 177
 
@@ -181,7 +181,7 @@  discard block
 block discarded – undo
181 181
 	 * @return EE_Event
182 182
 	 */
183 183
 	public function event() {
184
-		return $this->get_first_related( 'Event' );
184
+		return $this->get_first_related('Event');
185 185
 	}
186 186
 
187 187
 
@@ -195,7 +195,7 @@  discard block
 block discarded – undo
195 195
 	 */
196 196
 	public function wp_user() {
197 197
 		$event = $this->event();
198
-		if ( $event instanceof EE_Event ) {
198
+		if ($event instanceof EE_Event) {
199 199
 			return $event->wp_user();
200 200
 		}
201 201
 		return 0;
@@ -221,8 +221,8 @@  discard block
 block discarded – undo
221 221
 	 * @access        public
222 222
 	 * @param        int $ATT_ID Attendee ID
223 223
 	 */
224
-	public function set_attendee_id( $ATT_ID = 0 ) {
225
-		$this->set( 'ATT_ID', $ATT_ID );
224
+	public function set_attendee_id($ATT_ID = 0) {
225
+		$this->set('ATT_ID', $ATT_ID);
226 226
 	}
227 227
 
228 228
 
@@ -233,8 +233,8 @@  discard block
 block discarded – undo
233 233
 	 * @access        public
234 234
 	 * @param        int $TXN_ID Transaction ID
235 235
 	 */
236
-	public function set_transaction_id( $TXN_ID = 0 ) {
237
-		$this->set( 'TXN_ID', $TXN_ID );
236
+	public function set_transaction_id($TXN_ID = 0) {
237
+		$this->set('TXN_ID', $TXN_ID);
238 238
 	}
239 239
 
240 240
 
@@ -245,8 +245,8 @@  discard block
 block discarded – undo
245 245
 	 * @access    public
246 246
 	 * @param    string $REG_session PHP Session ID
247 247
 	 */
248
-	public function set_session( $REG_session = '' ) {
249
-		$this->set( 'REG_session', $REG_session );
248
+	public function set_session($REG_session = '') {
249
+		$this->set('REG_session', $REG_session);
250 250
 	}
251 251
 
252 252
 
@@ -257,8 +257,8 @@  discard block
 block discarded – undo
257 257
 	 * @access    public
258 258
 	 * @param    string $REG_url_link Registration URL Link
259 259
 	 */
260
-	public function set_reg_url_link( $REG_url_link = '' ) {
261
-		$this->set( 'REG_url_link', $REG_url_link );
260
+	public function set_reg_url_link($REG_url_link = '') {
261
+		$this->set('REG_url_link', $REG_url_link);
262 262
 	}
263 263
 
264 264
 
@@ -269,8 +269,8 @@  discard block
 block discarded – undo
269 269
 	 * @access        public
270 270
 	 * @param        int $REG_count Primary Attendee
271 271
 	 */
272
-	public function set_count( $REG_count = 1 ) {
273
-		$this->set( 'REG_count', $REG_count );
272
+	public function set_count($REG_count = 1) {
273
+		$this->set('REG_count', $REG_count);
274 274
 	}
275 275
 
276 276
 
@@ -281,8 +281,8 @@  discard block
 block discarded – undo
281 281
 	 * @access        public
282 282
 	 * @param        boolean $REG_group_size Group Registration
283 283
 	 */
284
-	public function set_group_size( $REG_group_size = FALSE ) {
285
-		$this->set( 'REG_group_size', $REG_group_size );
284
+	public function set_group_size($REG_group_size = FALSE) {
285
+		$this->set('REG_group_size', $REG_group_size);
286 286
 	}
287 287
 
288 288
 
@@ -365,8 +365,8 @@  discard block
 block discarded – undo
365 365
 	 * @access        public
366 366
 	 * @param        mixed ( int or string ) $REG_date Registration Date - Unix timestamp or string representation of Date
367 367
 	 */
368
-	public function set_reg_date( $REG_date = FALSE ) {
369
-		$this->set( 'REG_date', $REG_date );
368
+	public function set_reg_date($REG_date = FALSE) {
369
+		$this->set('REG_date', $REG_date);
370 370
 	}
371 371
 
372 372
 
@@ -377,8 +377,8 @@  discard block
 block discarded – undo
377 377
 	 * @access    public
378 378
 	 * @param    float $REG_final_price
379 379
 	 */
380
-	public function set_final_price( $REG_final_price = 0.00 ) {
381
-		$this->set( 'REG_final_price', $REG_final_price );
380
+	public function set_final_price($REG_final_price = 0.00) {
381
+		$this->set('REG_final_price', $REG_final_price);
382 382
 	}
383 383
 
384 384
 
@@ -389,8 +389,8 @@  discard block
 block discarded – undo
389 389
 	 * @access    public
390 390
 	 * @param    float $REG_paid
391 391
 	 */
392
-	public function set_paid( $REG_paid = 0.00 ) {
393
-		$this->set( 'REG_paid', $REG_paid );
392
+	public function set_paid($REG_paid = 0.00) {
393
+		$this->set('REG_paid', $REG_paid);
394 394
 	}
395 395
 
396 396
 
@@ -401,8 +401,8 @@  discard block
 block discarded – undo
401 401
 	 * @access        public
402 402
 	 * @param        boolean $REG_att_is_going Attendee Is Going
403 403
 	 */
404
-	public function set_att_is_going( $REG_att_is_going = FALSE ) {
405
-		$this->set( 'REG_att_is_going', $REG_att_is_going );
404
+	public function set_att_is_going($REG_att_is_going = FALSE) {
405
+		$this->set('REG_att_is_going', $REG_att_is_going);
406 406
 	}
407 407
 
408 408
 
@@ -412,7 +412,7 @@  discard block
 block discarded – undo
412 412
 	 * @return EE_Attendee
413 413
 	 */
414 414
 	public function attendee() {
415
-		return $this->get_first_related( 'Attendee' );
415
+		return $this->get_first_related('Attendee');
416 416
 	}
417 417
 
418 418
 
@@ -422,7 +422,7 @@  discard block
 block discarded – undo
422 422
 	 * @access        public
423 423
 	 */
424 424
 	public function event_ID() {
425
-		return $this->get( 'EVT_ID' );
425
+		return $this->get('EVT_ID');
426 426
 	}
427 427
 
428 428
 
@@ -433,7 +433,7 @@  discard block
 block discarded – undo
433 433
 	 */
434 434
 	public function event_name() {
435 435
 		$event = $this->event_obj();
436
-		if ( $event ) {
436
+		if ($event) {
437 437
 			return $event->name();
438 438
 		} else {
439 439
 			return NULL;
@@ -447,7 +447,7 @@  discard block
 block discarded – undo
447 447
 	 * @return EE_Event
448 448
 	 */
449 449
 	public function event_obj() {
450
-		return $this->get_first_related( 'Event' );
450
+		return $this->get_first_related('Event');
451 451
 	}
452 452
 
453 453
 
@@ -457,7 +457,7 @@  discard block
 block discarded – undo
457 457
 	 * @access        public
458 458
 	 */
459 459
 	public function attendee_ID() {
460
-		return $this->get( 'ATT_ID' );
460
+		return $this->get('ATT_ID');
461 461
 	}
462 462
 
463 463
 
@@ -467,7 +467,7 @@  discard block
 block discarded – undo
467 467
 	 * @access        public
468 468
 	 */
469 469
 	public function session_ID() {
470
-		return $this->get( 'REG_session' );
470
+		return $this->get('REG_session');
471 471
 	}
472 472
 
473 473
 
@@ -477,7 +477,7 @@  discard block
 block discarded – undo
477 477
 	 * @param string $messenger 'pdf' or 'html'.  Default 'html'.
478 478
 	 * @return string
479 479
 	 */
480
-	public function receipt_url( $messenger = 'html' ) {
480
+	public function receipt_url($messenger = 'html') {
481 481
 
482 482
 		/**
483 483
 		 * The below will be deprecated one version after this.  We check first if there is a custom receipt template already in use on old system.  If there is then we just return the standard url for it.
@@ -486,12 +486,12 @@  discard block
 block discarded – undo
486 486
 		 */
487 487
 		EE_Registry::instance()->load_helper('Template');
488 488
 		$template_relative_path = 'modules/gateways/Invoice/lib/templates/receipt_body.template.php';
489
-		$has_custom = EEH_Template::locate_template( $template_relative_path , array(), TRUE, TRUE, TRUE );
489
+		$has_custom = EEH_Template::locate_template($template_relative_path, array(), TRUE, TRUE, TRUE);
490 490
 
491
-		if ( $has_custom ) {
492
-			return add_query_arg( array( 'receipt' => 'true' ), $this->invoice_url( 'launch' ) );
491
+		if ($has_custom) {
492
+			return add_query_arg(array('receipt' => 'true'), $this->invoice_url('launch'));
493 493
 		}
494
-		return apply_filters( 'FHEE__EE_Registration__receipt_url__receipt_url', '', $this, $messenger, 'receipt' );
494
+		return apply_filters('FHEE__EE_Registration__receipt_url__receipt_url', '', $this, $messenger, 'receipt');
495 495
 	}
496 496
 
497 497
 
@@ -502,7 +502,7 @@  discard block
 block discarded – undo
502 502
 	 * @param string $messenger 'pdf' or 'html'.  Default 'html'.
503 503
 	 * @return string
504 504
 	 */
505
-	public function invoice_url( $messenger = 'html' ) {
505
+	public function invoice_url($messenger = 'html') {
506 506
 		/**
507 507
 		 * The below will be deprecated one version after this.  We check first if there is a custom invoice template already in use on old system.  If there is then we just return the standard url for it.
508 508
 		 *
@@ -510,21 +510,21 @@  discard block
 block discarded – undo
510 510
 		 */
511 511
 		EE_Registry::instance()->load_helper('Template');
512 512
 		$template_relative_path = 'modules/gateways/Invoice/lib/templates/invoice_body.template.php';
513
-		$has_custom = EEH_Template::locate_template( $template_relative_path , array(), TRUE, TRUE, TRUE );
513
+		$has_custom = EEH_Template::locate_template($template_relative_path, array(), TRUE, TRUE, TRUE);
514 514
 
515
-		if ( $has_custom ) {
516
-			if ( $messenger == 'html' ) {
517
-				return $this->invoice_url( 'launch' );
515
+		if ($has_custom) {
516
+			if ($messenger == 'html') {
517
+				return $this->invoice_url('launch');
518 518
 			}
519 519
 			$route = $messenger == 'download' || $messenger == 'pdf' ? 'download_invoice' : 'launch_invoice';
520 520
 
521
-			$query_args = array( 'ee' => $route, 'id' => $this->reg_url_link() );
522
-			if ( $messenger == 'html' ) {
521
+			$query_args = array('ee' => $route, 'id' => $this->reg_url_link());
522
+			if ($messenger == 'html') {
523 523
 				$query_args['html'] = TRUE;
524 524
 			}
525
-			return add_query_arg( $query_args, get_permalink( EE_Registry::instance()->CFG->core->thank_you_page_id ) );
525
+			return add_query_arg($query_args, get_permalink(EE_Registry::instance()->CFG->core->thank_you_page_id));
526 526
 		}
527
-		return apply_filters( 'FHEE__EE_Registration__invoice_url__invoice_url', '', $this, $messenger, 'invoice' );
527
+		return apply_filters('FHEE__EE_Registration__invoice_url__invoice_url', '', $this, $messenger, 'invoice');
528 528
 	}
529 529
 
530 530
 
@@ -537,7 +537,7 @@  discard block
 block discarded – undo
537 537
 	 * @throws \EE_Error
538 538
 	 */
539 539
 	public function reg_url_link() {
540
-		return (string)$this->get( 'REG_url_link' );
540
+		return (string) $this->get('REG_url_link');
541 541
 	}
542 542
 
543 543
 
@@ -547,8 +547,8 @@  discard block
 block discarded – undo
547 547
 	 * @param string $type 'download','launch', or 'html' (default is 'launch')
548 548
 	 * @return void
549 549
 	 */
550
-	public function e_invoice_url( $type = 'launch' ) {
551
-		echo $this->invoice_url( $type );
550
+	public function e_invoice_url($type = 'launch') {
551
+		echo $this->invoice_url($type);
552 552
 	}
553 553
 
554 554
 
@@ -568,7 +568,7 @@  discard block
 block discarded – undo
568 568
 	 * @return string
569 569
 	 */
570 570
 	public function payment_overview_url() {
571
-		return add_query_arg( array( 'e_reg_url_link' => $this->reg_url_link(), 'step' => 'payment_options', 'revisit' => TRUE ), EE_Registry::instance()->CFG->core->reg_page_url() );
571
+		return add_query_arg(array('e_reg_url_link' => $this->reg_url_link(), 'step' => 'payment_options', 'revisit' => TRUE), EE_Registry::instance()->CFG->core->reg_page_url());
572 572
 	}
573 573
 
574 574
 
@@ -579,7 +579,7 @@  discard block
 block discarded – undo
579 579
 	 * @return string
580 580
 	 */
581 581
 	public function edit_attendee_information_url() {
582
-		return add_query_arg( array( 'e_reg_url_link' => $this->reg_url_link(), 'step' => 'attendee_information', 'revisit' => TRUE ), EE_Registry::instance()->CFG->core->reg_page_url() );
582
+		return add_query_arg(array('e_reg_url_link' => $this->reg_url_link(), 'step' => 'attendee_information', 'revisit' => TRUE), EE_Registry::instance()->CFG->core->reg_page_url());
583 583
 	}
584 584
 
585 585
 
@@ -589,8 +589,8 @@  discard block
 block discarded – undo
589 589
 	 * @return string
590 590
 	 */
591 591
 	public function get_admin_edit_url() {
592
-		EE_Registry::instance()->load_helper( 'URL' );
593
-		return EEH_URL::add_query_args_and_nonce( array( 'page' => 'espresso_registrations', 'action' => 'view_registration', '_REG_ID' => $this->ID() ), admin_url( 'admin.php' ) );
592
+		EE_Registry::instance()->load_helper('URL');
593
+		return EEH_URL::add_query_args_and_nonce(array('page' => 'espresso_registrations', 'action' => 'view_registration', '_REG_ID' => $this->ID()), admin_url('admin.php'));
594 594
 	}
595 595
 
596 596
 
@@ -600,7 +600,7 @@  discard block
 block discarded – undo
600 600
 	 * @access        public
601 601
 	 */
602 602
 	public function is_primary_registrant() {
603
-		return $this->get( 'REG_count' ) == 1 ? TRUE : FALSE;
603
+		return $this->get('REG_count') == 1 ? TRUE : FALSE;
604 604
 	}
605 605
 
606 606
 
@@ -609,12 +609,12 @@  discard block
 block discarded – undo
609 609
 	 * This returns the primary registration object for this registration group (which may be this object).
610 610
 	 * @return EE_Registration
611 611
 	 */
612
-	public function get_primary_registration()  {
613
-		if ( $this->is_primary_registrant() )
612
+	public function get_primary_registration() {
613
+		if ($this->is_primary_registrant())
614 614
 			return $this;
615 615
 
616 616
 		//k reg_count !== 1 so let's get the EE_Registration object matching this txn_id and reg_count == 1
617
-		$primary_registrant = EEM_Registration::instance()->get_one( array( array('TXN_ID' => $this->transaction_ID(), 'REG_count' => 1 ) ) );
617
+		$primary_registrant = EEM_Registration::instance()->get_one(array(array('TXN_ID' => $this->transaction_ID(), 'REG_count' => 1)));
618 618
 		return $primary_registrant;
619 619
 	}
620 620
 
@@ -625,7 +625,7 @@  discard block
 block discarded – undo
625 625
 	* 		@access		public
626 626
 	*/
627 627
 	public function count() {
628
-		return $this->get( 'REG_count' );
628
+		return $this->get('REG_count');
629 629
 	}
630 630
 
631 631
 
@@ -635,7 +635,7 @@  discard block
 block discarded – undo
635 635
 	 * @access        public
636 636
 	 */
637 637
 	public function group_size() {
638
-		return $this->get( 'REG_group_size' );
638
+		return $this->get('REG_group_size');
639 639
 	}
640 640
 
641 641
 
@@ -645,7 +645,7 @@  discard block
 block discarded – undo
645 645
 	 * @access        public
646 646
 	 */
647 647
 	public function date() {
648
-		return $this->get( 'REG_date' );
648
+		return $this->get('REG_date');
649 649
 	}
650 650
 
651 651
 
@@ -656,8 +656,8 @@  discard block
 block discarded – undo
656 656
 	 * @param string $time_format
657 657
 	 * @return string
658 658
 	 */
659
-	public function pretty_date( $date_format = NULL, $time_format = NULL ) {
660
-		return $this->get_datetime( 'REG_date', $date_format, $time_format );
659
+	public function pretty_date($date_format = NULL, $time_format = NULL) {
660
+		return $this->get_datetime('REG_date', $date_format, $time_format);
661 661
 	}
662 662
 
663 663
 
@@ -670,7 +670,7 @@  discard block
 block discarded – undo
670 670
 	 * @return    float
671 671
 	 */
672 672
 	public function final_price() {
673
-		return $this->get( 'REG_final_price' );
673
+		return $this->get('REG_final_price');
674 674
 	}
675 675
 
676 676
 
@@ -681,7 +681,7 @@  discard block
 block discarded – undo
681 681
 	 * @return string
682 682
 	 */
683 683
 	public function pretty_final_price() {
684
-		return $this->get_pretty( 'REG_final_price' );
684
+		return $this->get_pretty('REG_final_price');
685 685
 	}
686 686
 
687 687
 
@@ -692,7 +692,7 @@  discard block
 block discarded – undo
692 692
 	 * @return 	float
693 693
 	 */
694 694
 	public function paid() {
695
-		return $this->get( 'REG_paid' );
695
+		return $this->get('REG_paid');
696 696
 	}
697 697
 
698 698
 
@@ -703,7 +703,7 @@  discard block
 block discarded – undo
703 703
 	 * @return 	float
704 704
 	 */
705 705
 	public function pretty_paid() {
706
-		return $this->get_pretty( 'REG_paid' );
706
+		return $this->get_pretty('REG_paid');
707 707
 	}
708 708
 
709 709
 
@@ -715,11 +715,11 @@  discard block
 block discarded – undo
715 715
 	 * @param array $requires_payment
716 716
 	 * @return bool
717 717
 	 */
718
-	public function owes_monies_and_can_pay( $requires_payment = array()) {
718
+	public function owes_monies_and_can_pay($requires_payment = array()) {
719 719
 		// these reg statuses require payment (if event is not free)
720
-		$requires_payment = ! empty( $requires_payment ) ? $requires_payment : EEM_Registration::reg_statuses_that_allow_payment();
720
+		$requires_payment = ! empty($requires_payment) ? $requires_payment : EEM_Registration::reg_statuses_that_allow_payment();
721 721
 		if (
722
-			in_array( $this->status_ID(), $requires_payment ) &&
722
+			in_array($this->status_ID(), $requires_payment) &&
723 723
 			$this->final_price() != 0 &&
724 724
 			$this->final_price() != $this->paid()
725 725
 		) {
@@ -736,8 +736,8 @@  discard block
 block discarded – undo
736 736
 	 * @param bool $show_icons
737 737
 	 * @return void
738 738
 	 */
739
-	public function e_pretty_status( $show_icons = FALSE ) {
740
-		echo $this->pretty_status( $show_icons );
739
+	public function e_pretty_status($show_icons = FALSE) {
740
+		echo $this->pretty_status($show_icons);
741 741
 	}
742 742
 
743 743
 
@@ -748,10 +748,10 @@  discard block
 block discarded – undo
748 748
 	 * @param bool $show_icons
749 749
 	 * @return string
750 750
 	 */
751
-	public function pretty_status( $show_icons = FALSE ) {
752
-		$status = EEM_Status::instance()->localized_status( array( $this->status_ID() => __( 'unknown', 'event_espresso' ) ), FALSE, 'sentence' );
751
+	public function pretty_status($show_icons = FALSE) {
752
+		$status = EEM_Status::instance()->localized_status(array($this->status_ID() => __('unknown', 'event_espresso')), FALSE, 'sentence');
753 753
 		$icon = '';
754
-		switch ( $this->status_ID() ) {
754
+		switch ($this->status_ID()) {
755 755
 			case EEM_Registration::status_id_approved:
756 756
 				$icon = $show_icons ? '<span class="dashicons dashicons-star-filled ee-icon-size-16 green-text"></span>' : '';
757 757
 				break;
@@ -771,7 +771,7 @@  discard block
 block discarded – undo
771 771
 				$icon = $show_icons ? '<span class="dashicons dashicons-no ee-icon-size-16 red-text"></span>' : '';
772 772
 				break;
773 773
 		}
774
-		return $icon . $status[ $this->status_ID() ];
774
+		return $icon.$status[$this->status_ID()];
775 775
 	}
776 776
 
777 777
 
@@ -781,7 +781,7 @@  discard block
 block discarded – undo
781 781
 	 * @access        public
782 782
 	 */
783 783
 	public function att_is_going() {
784
-		return $this->get( 'REG_att_is_going' );
784
+		return $this->get('REG_att_is_going');
785 785
 	}
786 786
 
787 787
 
@@ -791,8 +791,8 @@  discard block
 block discarded – undo
791 791
 	 * @param array $query_params like EEM_Base::get_all
792 792
 	 * @return EE_Answer[]
793 793
 	 */
794
-	public function answers( $query_params = NULL ) {
795
-		return $this->get_many_related( 'Answer', $query_params );
794
+	public function answers($query_params = NULL) {
795
+		return $this->get_many_related('Answer', $query_params);
796 796
 	}
797 797
 
798 798
 
@@ -806,9 +806,9 @@  discard block
 block discarded – undo
806 806
 	 * (because the answer might be an array of answer values, so passing pretty_value=true
807 807
 	 * will convert it into some kind of string)
808 808
 	 */
809
-	public function answer_value_to_question( $question, $pretty_value=true ) {
809
+	public function answer_value_to_question($question, $pretty_value = true) {
810 810
 		$question_id = EEM_Question::instance()->ensure_is_ID($question);
811
-		return EEM_Answer::instance()->get_answer_value_to_question($this,$question_id,$pretty_value);
811
+		return EEM_Answer::instance()->get_answer_value_to_question($this, $question_id, $pretty_value);
812 812
 	}
813 813
 
814 814
 
@@ -821,13 +821,13 @@  discard block
 block discarded – undo
821 821
 	 */
822 822
 	public function question_groups() {
823 823
 		$question_groups = array();
824
-		if ( $this->event() instanceof EE_Event ) {
824
+		if ($this->event() instanceof EE_Event) {
825 825
 			$question_groups = $this->event()->question_groups(
826 826
 				array(
827 827
 					array(
828 828
 						'Event_Question_Group.EQG_primary' => $this->count() == 1 ? true : false
829 829
 					),
830
-					'order_by' => array( 'QSG_order' => 'ASC' )
830
+					'order_by' => array('QSG_order' => 'ASC')
831 831
 				)
832 832
 			);
833 833
 		}
@@ -844,7 +844,7 @@  discard block
 block discarded – undo
844 844
 	 */
845 845
 	public function count_question_groups() {
846 846
 		$qg_count = 0;
847
-		if ( $this->event() instanceof EE_Event ) {
847
+		if ($this->event() instanceof EE_Event) {
848 848
 			$qg_count = $this->event()->count_related(
849 849
 				'Question_Group',
850 850
 				array(
@@ -865,7 +865,7 @@  discard block
 block discarded – undo
865 865
 	 * @return string
866 866
 	 */
867 867
 	public function reg_date() {
868
-		return $this->get_datetime( 'REG_date' );
868
+		return $this->get_datetime('REG_date');
869 869
 	}
870 870
 
871 871
 
@@ -877,7 +877,7 @@  discard block
 block discarded – undo
877 877
 	 * @return EE_Datetime_Ticket
878 878
 	 */
879 879
 	public function datetime_ticket() {
880
-		return $this->get_first_related( 'Datetime_Ticket' );
880
+		return $this->get_first_related('Datetime_Ticket');
881 881
 	}
882 882
 
883 883
 
@@ -887,15 +887,15 @@  discard block
 block discarded – undo
887 887
 	 * @param EE_Datetime_Ticket $datetime_ticket
888 888
 	 * @return EE_Datetime_Ticket
889 889
 	 */
890
-	public function set_datetime_ticket( $datetime_ticket ) {
891
-		return $this->_add_relation_to( $datetime_ticket, 'Datetime_Ticket' );
890
+	public function set_datetime_ticket($datetime_ticket) {
891
+		return $this->_add_relation_to($datetime_ticket, 'Datetime_Ticket');
892 892
 	}
893 893
 	/**
894 894
 	 * Gets deleted
895 895
 	 * @return boolean
896 896
 	 */
897 897
 	public function deleted() {
898
-		return $this->get( 'REG_deleted' );
898
+		return $this->get('REG_deleted');
899 899
 	}
900 900
 
901 901
 	/**
@@ -904,7 +904,7 @@  discard block
 block discarded – undo
904 904
 	 * @return boolean
905 905
 	 */
906 906
 	public function set_deleted($deleted) {
907
-		$this->set( 'REG_deleted', $deleted );
907
+		$this->set('REG_deleted', $deleted);
908 908
 	}
909 909
 
910 910
 
@@ -914,7 +914,7 @@  discard block
 block discarded – undo
914 914
 	 * @return EE_Status
915 915
 	 */
916 916
 	public function status_obj() {
917
-		return $this->get_first_related( 'Status' );
917
+		return $this->get_first_related('Status');
918 918
 	}
919 919
 
920 920
 
@@ -925,7 +925,7 @@  discard block
 block discarded – undo
925 925
 	 * @return int
926 926
 	 */
927 927
 	public function count_checkins() {
928
-		return $this->get_model()->count_related( $this, 'Checkin' );
928
+		return $this->get_model()->count_related($this, 'Checkin');
929 929
 	}
930 930
 
931 931
 
@@ -935,7 +935,7 @@  discard block
 block discarded – undo
935 935
 	 * @return int
936 936
 	 */
937 937
 	public function count_checkins_not_checkedout() {
938
-		return $this->get_model()->count_related( $this, 'Checkin', array( array( 'CHK_in' => 1 ) ) );
938
+		return $this->get_model()->count_related($this, 'Checkin', array(array('CHK_in' => 1)));
939 939
 	}
940 940
 
941 941
 
@@ -948,20 +948,20 @@  discard block
 block discarded – undo
948 948
 	 *
949 949
 	 * @return bool
950 950
 	 */
951
-	public function can_checkin( $DTT_OR_ID, $check_approved = TRUE ) {
952
-		$DTT_ID = EEM_Datetime::instance()->ensure_is_ID( $DTT_OR_ID );
951
+	public function can_checkin($DTT_OR_ID, $check_approved = TRUE) {
952
+		$DTT_ID = EEM_Datetime::instance()->ensure_is_ID($DTT_OR_ID);
953 953
 
954 954
 		//first check registration status
955
-		if (  ( $check_approved && ! $this->is_approved() ) || ! $DTT_ID ) {
955
+		if (($check_approved && ! $this->is_approved()) || ! $DTT_ID) {
956 956
 			return false;
957 957
 		}
958 958
 		//is there a datetime ticket that matches this dtt_ID?
959
-		if ( ! ( EEM_Datetime_Ticket::instance()->exists( array( array( 'TKT_ID' => $this->get('TKT_ID' ), 'DTT_ID' => $DTT_ID ) ) ) ) ) {
959
+		if ( ! (EEM_Datetime_Ticket::instance()->exists(array(array('TKT_ID' => $this->get('TKT_ID'), 'DTT_ID' => $DTT_ID))))) {
960 960
 			return false;
961 961
 		}
962 962
 
963 963
 		//final check is against TKT_uses
964
-		return $this->verify_can_checkin_against_TKT_uses( $DTT_ID );
964
+		return $this->verify_can_checkin_against_TKT_uses($DTT_ID);
965 965
 	}
966 966
 
967 967
 
@@ -974,10 +974,10 @@  discard block
 block discarded – undo
974 974
 	 * @param int | EE_Datetime  $DTT_OR_ID  The datetime the registration is being checked against
975 975
 	 * @return bool   true means can checkin.  false means cannot checkin.
976 976
 	 */
977
-	public function verify_can_checkin_against_TKT_uses( $DTT_OR_ID ) {
978
-		$DTT_ID = EEM_Datetime::instance()->ensure_is_ID( $DTT_OR_ID );
977
+	public function verify_can_checkin_against_TKT_uses($DTT_OR_ID) {
978
+		$DTT_ID = EEM_Datetime::instance()->ensure_is_ID($DTT_OR_ID);
979 979
 
980
-		if ( ! $DTT_ID ) {
980
+		if ( ! $DTT_ID) {
981 981
 			return false;
982 982
 		}
983 983
 
@@ -985,23 +985,23 @@  discard block
 block discarded – undo
985 985
 
986 986
 		// if max uses is not set or equals infinity then return true cause its not a factor for whether user can check-in
987 987
 		// or not.
988
-		if ( ! $max_uses || $max_uses === EE_INF ) {
988
+		if ( ! $max_uses || $max_uses === EE_INF) {
989 989
 			return true;
990 990
 		}
991 991
 
992 992
 		//does this datetime have a checkin record?  If so, then the dtt count has already been verified so we can just
993 993
 		//go ahead and toggle.
994
-		if ( EEM_Checkin::instance()->exists( array( array( 'REG_ID' => $this->ID(), 'DTT_ID' => $DTT_ID ) ) ) ) {
994
+		if (EEM_Checkin::instance()->exists(array(array('REG_ID' => $this->ID(), 'DTT_ID' => $DTT_ID)))) {
995 995
 			return true;
996 996
 		}
997 997
 
998 998
 		//made it here so the last check is whether the number of checkins per unique datetime on this registration
999 999
 		//disallows further check-ins.
1000
-		$count_unique_dtt_checkins = EEM_Checkin::instance()->count( array( array( 'REG_ID' => $this->ID(), 'CHK_in' => true ) ), 'DTT_ID', true );
1000
+		$count_unique_dtt_checkins = EEM_Checkin::instance()->count(array(array('REG_ID' => $this->ID(), 'CHK_in' => true)), 'DTT_ID', true);
1001 1001
 		// checkins have already reached their max number of uses
1002 1002
 		// so registrant can NOT checkin
1003
-		if ( $count_unique_dtt_checkins >= $max_uses ) {
1004
-			EE_Error::add_error( __( 'Check-in denied because number of datetime uses for the ticket has been reached or exceeded.', 'event_espresso' ), __FILE__, __FUNCTION__, __LINE__ );
1003
+		if ($count_unique_dtt_checkins >= $max_uses) {
1004
+			EE_Error::add_error(__('Check-in denied because number of datetime uses for the ticket has been reached or exceeded.', 'event_espresso'), __FILE__, __FUNCTION__, __LINE__);
1005 1005
 			return false;
1006 1006
 		}
1007 1007
 		return true;
@@ -1022,15 +1022,15 @@  discard block
 block discarded – undo
1022 1022
 	 * @param  bool $verify  If true then can_checkin() is used to verify whether the person can be checked in or not.  Otherwise this forces change in checkin status.
1023 1023
 	 * @return int|BOOL            the chk_in status toggled to OR false if nothing got changed.
1024 1024
 	 */
1025
-	public function toggle_checkin_status( $DTT_ID = null, $verify = false ) {
1026
-		if ( empty( $DTT_ID ) ) {
1025
+	public function toggle_checkin_status($DTT_ID = null, $verify = false) {
1026
+		if (empty($DTT_ID)) {
1027 1027
 			$datetime = $this->get_related_primary_datetime();
1028 1028
 			$DTT_ID = $datetime->ID();
1029 1029
 		// verify the registration can checkin for the given DTT_ID
1030
-		} elseif ( ! $this->can_checkin( $DTT_ID, $verify ) ) {
1030
+		} elseif ( ! $this->can_checkin($DTT_ID, $verify)) {
1031 1031
 			EE_Error::add_error(
1032 1032
 					sprintf(
1033
-						__( 'The given registration (ID:%1$d) can not be checked in to the given DTT_ID (%2$d), because the registration does not have access', 'event_espresso'),
1033
+						__('The given registration (ID:%1$d) can not be checked in to the given DTT_ID (%2$d), because the registration does not have access', 'event_espresso'),
1034 1034
 						$this->ID(),
1035 1035
 						$DTT_ID
1036 1036
 					),
@@ -1044,8 +1044,8 @@  discard block
 block discarded – undo
1044 1044
 			EE_Registration::checkin_status_out => EE_Registration::checkin_status_in
1045 1045
 		);
1046 1046
 		//start by getting the current status so we know what status we'll be changing to.
1047
-		$cur_status = $this->check_in_status_for_datetime( $DTT_ID, NULL );
1048
-		$status_to = $status_paths[ $cur_status ];
1047
+		$cur_status = $this->check_in_status_for_datetime($DTT_ID, NULL);
1048
+		$status_to = $status_paths[$cur_status];
1049 1049
 		// database only records true for checked IN or false for checked OUT
1050 1050
 		// no record ( null ) means checked in NEVER, but we obviously don't save that
1051 1051
 		$new_status = $status_to == EE_Registration::checkin_status_in ? true : false;
@@ -1053,24 +1053,24 @@  discard block
 block discarded – undo
1053 1053
 		// because we are keeping track of Check-ins over time.
1054 1054
 		// Eventually we'll probably want to show a list table
1055 1055
 		// for the individual Check-ins so that they can be managed.
1056
-		$checkin = EE_Checkin::new_instance( array(
1056
+		$checkin = EE_Checkin::new_instance(array(
1057 1057
 				'REG_ID' => $this->ID(),
1058 1058
 				'DTT_ID' => $DTT_ID,
1059 1059
 				'CHK_in' => $new_status
1060
-		) );
1060
+		));
1061 1061
 		// if the record could not be saved then return false
1062
-		if ( $checkin->save() === 0 ) {
1063
-			if ( WP_DEBUG ) {
1062
+		if ($checkin->save() === 0) {
1063
+			if (WP_DEBUG) {
1064 1064
 				global $wpdb;
1065 1065
 				$error = sprintf(
1066
-					__( 'Registration check in update failed because of the following database error: %1$s%2$s', 'event_espresso' ),
1066
+					__('Registration check in update failed because of the following database error: %1$s%2$s', 'event_espresso'),
1067 1067
 					'<br />',
1068 1068
 					$wpdb->last_error
1069 1069
 				);
1070 1070
 			} else {
1071
-				$error = __( 'Registration check in update failed because of an unknown database error', 'event_espresso' );
1071
+				$error = __('Registration check in update failed because of an unknown database error', 'event_espresso');
1072 1072
 			}
1073
-			EE_Error::add_error( $error, __FILE__, __FUNCTION__, __LINE__ );
1073
+			EE_Error::add_error($error, __FILE__, __FUNCTION__, __LINE__);
1074 1074
 			return false;
1075 1075
 		}
1076 1076
 		return $status_to;
@@ -1094,19 +1094,19 @@  discard block
 block discarded – undo
1094 1094
 	 * @param EE_Checkin $checkin If present, we use the given checkin object rather than the dtt_id.
1095 1095
 	 * @return int            Integer representing Check-in status.
1096 1096
 	 */
1097
-	public function check_in_status_for_datetime( $DTT_ID = 0, $checkin = NULL ) {
1098
-		if ( empty( $DTT_ID ) && ! $checkin instanceof EE_Checkin ) {
1097
+	public function check_in_status_for_datetime($DTT_ID = 0, $checkin = NULL) {
1098
+		if (empty($DTT_ID) && ! $checkin instanceof EE_Checkin) {
1099 1099
 			$datetime = $this->get_related_primary_datetime();
1100
-			if ( ! $datetime instanceof EE_Datetime ) {
1100
+			if ( ! $datetime instanceof EE_Datetime) {
1101 1101
 				return 0;
1102 1102
 			}
1103 1103
 			$DTT_ID = $datetime->ID();
1104 1104
 		//verify the registration can checkin for the given DTT_ID
1105 1105
 		}
1106 1106
 		//get checkin object (if exists)
1107
-		$checkin = $checkin instanceof EE_Checkin ? $checkin : $this->get_first_related( 'Checkin', array( array( 'DTT_ID' => $DTT_ID ), 'order_by' => array( 'CHK_timestamp' => 'DESC' ) ) );
1108
-		if ( $checkin instanceof EE_Checkin ) {
1109
-			if ( $checkin->get( 'CHK_in' ) ) {
1107
+		$checkin = $checkin instanceof EE_Checkin ? $checkin : $this->get_first_related('Checkin', array(array('DTT_ID' => $DTT_ID), 'order_by' => array('CHK_timestamp' => 'DESC')));
1108
+		if ($checkin instanceof EE_Checkin) {
1109
+			if ($checkin->get('CHK_in')) {
1110 1110
 				return EE_Registration::checkin_status_in; //checked in
1111 1111
 			} else {
1112 1112
 				return EE_Registration::checkin_status_out; //had checked in but is now checked out.
@@ -1124,28 +1124,28 @@  discard block
 block discarded – undo
1124 1124
 	 * @param bool $error  This just flags that you want an error message returned. This is put in so that the error message can be customized with the attendee name.
1125 1125
 	 * @return string         internationalized message
1126 1126
 	 */
1127
-	public function get_checkin_msg( $DTT_ID, $error = FALSE ) {
1127
+	public function get_checkin_msg($DTT_ID, $error = FALSE) {
1128 1128
 		//let's get the attendee first so we can include the name of the attendee
1129
-		$attendee = $this->get_first_related( 'Attendee' );
1130
-		if ( $attendee instanceof EE_Attendee ) {
1131
-			if ( $error ) {
1132
-				return sprintf( __( "%s's check-in status was not changed.", "event_espresso" ), $attendee->full_name() );
1129
+		$attendee = $this->get_first_related('Attendee');
1130
+		if ($attendee instanceof EE_Attendee) {
1131
+			if ($error) {
1132
+				return sprintf(__("%s's check-in status was not changed.", "event_espresso"), $attendee->full_name());
1133 1133
 			}
1134
-			$cur_status = $this->check_in_status_for_datetime( $DTT_ID );
1134
+			$cur_status = $this->check_in_status_for_datetime($DTT_ID);
1135 1135
 			//what is the status message going to be?
1136
-			switch ( $cur_status ) {
1136
+			switch ($cur_status) {
1137 1137
 				case EE_Registration::checkin_status_never :
1138
-					return sprintf( __( "%s has been removed from Check-in records", "event_espresso" ), $attendee->full_name() );
1138
+					return sprintf(__("%s has been removed from Check-in records", "event_espresso"), $attendee->full_name());
1139 1139
 					break;
1140 1140
 				case EE_Registration::checkin_status_in :
1141
-					return sprintf( __( '%s has been checked in', 'event_espresso' ), $attendee->full_name() );
1141
+					return sprintf(__('%s has been checked in', 'event_espresso'), $attendee->full_name());
1142 1142
 					break;
1143 1143
 				case EE_Registration::checkin_status_out :
1144
-					return sprintf( __( '%s has been checked out', 'event_espresso' ), $attendee->full_name() );
1144
+					return sprintf(__('%s has been checked out', 'event_espresso'), $attendee->full_name());
1145 1145
 					break;
1146 1146
 			}
1147 1147
 		}
1148
-		return __( "The check-in status could not be determined.", "event_espresso" );
1148
+		return __("The check-in status could not be determined.", "event_espresso");
1149 1149
 	}
1150 1150
 
1151 1151
 
@@ -1155,7 +1155,7 @@  discard block
 block discarded – undo
1155 1155
 	 * @return EE_Transaction
1156 1156
 	 */
1157 1157
 	public function transaction() {
1158
-		return $this->get_first_related( 'Transaction' );
1158
+		return $this->get_first_related('Transaction');
1159 1159
 	}
1160 1160
 
1161 1161
 
@@ -1166,7 +1166,7 @@  discard block
 block discarded – undo
1166 1166
 	 * @access        public
1167 1167
 	 */
1168 1168
 	public function reg_code() {
1169
-		return $this->get( 'REG_code' );
1169
+		return $this->get('REG_code');
1170 1170
 	}
1171 1171
 
1172 1172
 
@@ -1176,7 +1176,7 @@  discard block
 block discarded – undo
1176 1176
 	 * @access        public
1177 1177
 	 */
1178 1178
 	public function transaction_ID() {
1179
-		return $this->get( 'TXN_ID' );
1179
+		return $this->get('TXN_ID');
1180 1180
 	}
1181 1181
 
1182 1182
 
@@ -1185,7 +1185,7 @@  discard block
 block discarded – undo
1185 1185
 	 * @return int
1186 1186
 	 */
1187 1187
 	public function ticket_ID() {
1188
-		return $this->get( 'TKT_ID' );
1188
+		return $this->get('TKT_ID');
1189 1189
 	}
1190 1190
 
1191 1191
 
@@ -1197,17 +1197,17 @@  discard block
 block discarded – undo
1197 1197
 	 * @param    string $REG_code Registration Code
1198 1198
 	 * @param	boolean $use_default
1199 1199
 	 */
1200
-	public function set_reg_code( $REG_code, $use_default = FALSE ) {
1201
-		if ( empty( $REG_code )) {
1202
-			EE_Error::add_error( __( 'REG_code can not be empty.', 'event_espresso'), __FILE__, __FUNCTION__, __LINE__ );
1200
+	public function set_reg_code($REG_code, $use_default = FALSE) {
1201
+		if (empty($REG_code)) {
1202
+			EE_Error::add_error(__('REG_code can not be empty.', 'event_espresso'), __FILE__, __FUNCTION__, __LINE__);
1203 1203
 			return;
1204 1204
 		}
1205
-		if ( ! $this->reg_code() ) {
1206
-			parent::set( 'REG_code', $REG_code, $use_default );
1205
+		if ( ! $this->reg_code()) {
1206
+			parent::set('REG_code', $REG_code, $use_default);
1207 1207
 		} else {
1208 1208
 			EE_Error::doing_it_wrong(
1209
-				__CLASS__ . '::' . __FUNCTION__,
1210
-				__( 'Can not change a registration REG_code once it has been set.', 'event_espresso' ),
1209
+				__CLASS__.'::'.__FUNCTION__,
1210
+				__('Can not change a registration REG_code once it has been set.', 'event_espresso'),
1211 1211
 				'4.6.0'
1212 1212
 			);
1213 1213
 		}
@@ -1227,17 +1227,17 @@  discard block
 block discarded – undo
1227 1227
 	 * @return EE_Registration[]  or empty array if this isn't a group registration.
1228 1228
 	 */
1229 1229
 	public function get_all_other_registrations_in_group() {
1230
-		if ( $this->group_size() < 2 ) {
1230
+		if ($this->group_size() < 2) {
1231 1231
 			return array();
1232 1232
 		}
1233 1233
 
1234 1234
 		$query[0] = array(
1235 1235
 			'TXN_ID' => $this->transaction_ID(),
1236
-			'REG_ID' => array( '!=', $this->ID() ),
1236
+			'REG_ID' => array('!=', $this->ID()),
1237 1237
 			'TKT_ID' => $this->ticket_ID()
1238 1238
 			);
1239 1239
 
1240
-		$registrations = $this->get_model()->get_all( $query );
1240
+		$registrations = $this->get_model()->get_all($query);
1241 1241
 		return $registrations;
1242 1242
 	}
1243 1243
 
@@ -1247,8 +1247,8 @@  discard block
 block discarded – undo
1247 1247
 	 * @param array $query_params
1248 1248
 	 * @return \EE_Registration[]
1249 1249
 	 */
1250
-	public function payments( $query_params = array() ) {
1251
-		return $this->get_many_related( 'Payment', $query_params );
1250
+	public function payments($query_params = array()) {
1251
+		return $this->get_many_related('Payment', $query_params);
1252 1252
 	}
1253 1253
 
1254 1254
 
@@ -1257,8 +1257,8 @@  discard block
 block discarded – undo
1257 1257
 	 * @param array $query_params
1258 1258
 	 * @return \EE_Registration[]
1259 1259
 	 */
1260
-	public function registration_payments( $query_params = array() ) {
1261
-		return $this->get_many_related( 'Registration_Payment', $query_params );
1260
+	public function registration_payments($query_params = array()) {
1261
+		return $this->get_many_related('Registration_Payment', $query_params);
1262 1262
 	}
1263 1263
 
1264 1264
 
@@ -1269,7 +1269,7 @@  discard block
 block discarded – undo
1269 1269
 	 * @access 	public
1270 1270
 	 */
1271 1271
 	public function price_paid() {
1272
-		EE_Error::doing_it_wrong( 'EE_Registration::price_paid()', __( 'This method is deprecated, please use EE_Registration::final_price() instead.', 'event_espresso' ), '4.7.0' );
1272
+		EE_Error::doing_it_wrong('EE_Registration::price_paid()', __('This method is deprecated, please use EE_Registration::final_price() instead.', 'event_espresso'), '4.7.0');
1273 1273
 		return $this->final_price();
1274 1274
 	}
1275 1275
 
@@ -1281,9 +1281,9 @@  discard block
 block discarded – undo
1281 1281
 	 * @access    public
1282 1282
 	 * @param    float $REG_final_price
1283 1283
 	 */
1284
-	public function set_price_paid( $REG_final_price = 0.00 ) {
1285
-		EE_Error::doing_it_wrong( 'EE_Registration::set_price_paid()', __( 'This method is deprecated, please use EE_Registration::set_final_price() instead.', 'event_espresso' ), '4.7.0' );
1286
-		$this->set_final_price( $REG_final_price );
1284
+	public function set_price_paid($REG_final_price = 0.00) {
1285
+		EE_Error::doing_it_wrong('EE_Registration::set_price_paid()', __('This method is deprecated, please use EE_Registration::set_final_price() instead.', 'event_espresso'), '4.7.0');
1286
+		$this->set_final_price($REG_final_price);
1287 1287
 	}
1288 1288
 
1289 1289
 
@@ -1294,7 +1294,7 @@  discard block
 block discarded – undo
1294 1294
 	 * @return string
1295 1295
 	 */
1296 1296
 	public function pretty_price_paid() {
1297
-		EE_Error::doing_it_wrong( 'EE_Registration::pretty_price_paid()', __( 'This method is deprecated, please use EE_Registration::pretty_final_price() instead.', 'event_espresso' ), '4.7.0' );
1297
+		EE_Error::doing_it_wrong('EE_Registration::pretty_price_paid()', __('This method is deprecated, please use EE_Registration::pretty_final_price() instead.', 'event_espresso'), '4.7.0');
1298 1298
 		return $this->pretty_final_price();
1299 1299
 	}
1300 1300
 
@@ -1308,7 +1308,7 @@  discard block
 block discarded – undo
1308 1308
 	 * @return EE_Payment_Method|null
1309 1309
 	 */
1310 1310
 	public function payment_method() {
1311
-		return EEM_Payment_Method::instance()->get_last_used_for_registration( $this );
1311
+		return EEM_Payment_Method::instance()->get_last_used_for_registration($this);
1312 1312
 	}
1313 1313
 
1314 1314
 
Please login to merge, or discard this patch.
core/db_classes/EE_State.class.php 2 patches
Spacing   +20 added lines, -20 removed lines patch added patch discarded remove patch
@@ -1,5 +1,5 @@  discard block
 block discarded – undo
1
-<?php if ( !defined( 'EVENT_ESPRESSO_VERSION' ) ) {
2
-	exit( 'No direct script access allowed' );
1
+<?php if ( ! defined('EVENT_ESPRESSO_VERSION')) {
2
+	exit('No direct script access allowed');
3 3
 }
4 4
 /**
5 5
  * Event Espresso
@@ -32,9 +32,9 @@  discard block
 block discarded – undo
32 32
 	 * @param array $props_n_values
33 33
 	 * @return EE_State|mixed
34 34
 	 */
35
-	public static function new_instance( $props_n_values = array() ) {
36
-		$has_object = parent::_check_for_object( $props_n_values, __CLASS__ );
37
-		return $has_object ? $has_object : new self( $props_n_values );
35
+	public static function new_instance($props_n_values = array()) {
36
+		$has_object = parent::_check_for_object($props_n_values, __CLASS__);
37
+		return $has_object ? $has_object : new self($props_n_values);
38 38
 	}
39 39
 
40 40
 
@@ -43,8 +43,8 @@  discard block
 block discarded – undo
43 43
 	 * @param array $props_n_values
44 44
 	 * @return EE_State
45 45
 	 */
46
-	public static function new_instance_from_db( $props_n_values = array() ) {
47
-		return new self( $props_n_values, TRUE );
46
+	public static function new_instance_from_db($props_n_values = array()) {
47
+		return new self($props_n_values, TRUE);
48 48
 	}
49 49
 
50 50
 
@@ -53,7 +53,7 @@  discard block
 block discarded – undo
53 53
 	 * @return string
54 54
 	 */
55 55
 	public function country_iso() {
56
-		return $this->get( 'CNT_ISO' );
56
+		return $this->get('CNT_ISO');
57 57
 	}
58 58
 
59 59
 
@@ -62,7 +62,7 @@  discard block
 block discarded – undo
62 62
 	 * @return string
63 63
 	 */
64 64
 	public function abbrev() {
65
-		return $this->get( 'STA_abbrev' );
65
+		return $this->get('STA_abbrev');
66 66
 	}
67 67
 
68 68
 
@@ -71,7 +71,7 @@  discard block
 block discarded – undo
71 71
 	 * @return bool
72 72
 	 */
73 73
 	public function active() {
74
-		return $this->get( 'STA_active' );
74
+		return $this->get('STA_active');
75 75
 	}
76 76
 
77 77
 
@@ -80,7 +80,7 @@  discard block
 block discarded – undo
80 80
 	 * @return string
81 81
 	 */
82 82
 	public function name() {
83
-		return $this->get( 'STA_name' );
83
+		return $this->get('STA_name');
84 84
 	}
85 85
 
86 86
 
@@ -89,7 +89,7 @@  discard block
 block discarded – undo
89 89
 	 * @return EE_Country
90 90
 	 */
91 91
 	public function country() {
92
-		return $this->get_first_related( 'Country' );
92
+		return $this->get_first_related('Country');
93 93
 	}
94 94
 
95 95
 
@@ -97,8 +97,8 @@  discard block
 block discarded – undo
97 97
 	/**
98 98
 	 * @param $iso
99 99
 	 */
100
-	public function set_country_iso( $iso ) {
101
-		$this->set( 'CNT_ISO', $iso );
100
+	public function set_country_iso($iso) {
101
+		$this->set('CNT_ISO', $iso);
102 102
 	}
103 103
 
104 104
 
@@ -106,8 +106,8 @@  discard block
 block discarded – undo
106 106
 	/**
107 107
 	 * @param $abbrev
108 108
 	 */
109
-	public function set_abbrev( $abbrev ) {
110
-		$this->set( 'STA_abbrev', $abbrev );
109
+	public function set_abbrev($abbrev) {
110
+		$this->set('STA_abbrev', $abbrev);
111 111
 	}
112 112
 
113 113
 
@@ -115,8 +115,8 @@  discard block
 block discarded – undo
115 115
 	/**
116 116
 	 * @param $active
117 117
 	 */
118
-	public function set_active( $active ) {
119
-		$this->set( 'STA_active', $active );
118
+	public function set_active($active) {
119
+		$this->set('STA_active', $active);
120 120
 	}
121 121
 
122 122
 
@@ -124,8 +124,8 @@  discard block
 block discarded – undo
124 124
 	/**
125 125
 	 * @param $name
126 126
 	 */
127
-	public function set_name( $name ) {
128
-		$this->set( 'STA_name', $name );
127
+	public function set_name($name) {
128
+		$this->set('STA_name', $name);
129 129
 	}
130 130
 }
131 131
 
Please login to merge, or discard this patch.
Indentation   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -2,18 +2,18 @@
 block discarded – undo
2 2
 	exit( 'No direct script access allowed' );
3 3
 }
4 4
 /**
5
- * Event Espresso
6
- *
7
- * Event Registration and Management Plugin for WordPress
8
- *
9
- * @ package 		Event Espresso
10
- * @ author 		Event Espresso
11
- * @ copyright 	(c) 2008-2011 Event Espresso  All Rights Reserved.
12
- * @ license 		{@link http://eventespresso.com/support/terms-conditions/}   * see Plugin Licensing *
13
- * @ link 				{@link http://www.eventespresso.com}
14
- * @ since 			4.0
15
- *
16
- */
5
+	 * Event Espresso
6
+	 *
7
+	 * Event Registration and Management Plugin for WordPress
8
+	 *
9
+	 * @ package 		Event Espresso
10
+	 * @ author 		Event Espresso
11
+	 * @ copyright 	(c) 2008-2011 Event Espresso  All Rights Reserved.
12
+	 * @ license 		{@link http://eventespresso.com/support/terms-conditions/}   * see Plugin Licensing *
13
+	 * @ link 				{@link http://www.eventespresso.com}
14
+	 * @ since 			4.0
15
+	 *
16
+	 */
17 17
 
18 18
 
19 19
 
Please login to merge, or discard this patch.
core/db_classes/EE_Status.class.php 3 patches
Spacing   +25 added lines, -25 removed lines patch added patch discarded remove patch
@@ -1,5 +1,5 @@  discard block
 block discarded – undo
1
-<?php if ( !defined( 'EVENT_ESPRESSO_VERSION' ) ) {
2
-	exit( 'No direct script access allowed' );
1
+<?php if ( ! defined('EVENT_ESPRESSO_VERSION')) {
2
+	exit('No direct script access allowed');
3 3
 }
4 4
 /**
5 5
  * Event Espresso
@@ -32,9 +32,9 @@  discard block
 block discarded – undo
32 32
 	 * @param array $props_n_values
33 33
 	 * @return EE_Status
34 34
 	 */
35
-	public static function new_instance( $props_n_values = array() ) {
36
-		$has_object = parent::_check_for_object( $props_n_values, __CLASS__ );
37
-		return $has_object ? $has_object : new self( $props_n_values );
35
+	public static function new_instance($props_n_values = array()) {
36
+		$has_object = parent::_check_for_object($props_n_values, __CLASS__);
37
+		return $has_object ? $has_object : new self($props_n_values);
38 38
 	}
39 39
 
40 40
 
@@ -43,8 +43,8 @@  discard block
 block discarded – undo
43 43
 	 * @param array $props_n_values
44 44
 	 * @return EE_Status
45 45
 	 */
46
-	public static function new_instance_from_db( $props_n_values = array() ) {
47
-		return new self( $props_n_values, TRUE );
46
+	public static function new_instance_from_db($props_n_values = array()) {
47
+		return new self($props_n_values, TRUE);
48 48
 	}
49 49
 
50 50
 
@@ -55,10 +55,10 @@  discard block
 block discarded – undo
55 55
 	 * @param string $schema
56 56
 	 * @return string
57 57
 	 */
58
-	function code( $plural = FALSE, $schema = 'upper' ) {
59
-		$id = $this->get( 'STS_ID' );
60
-		$code = EEM_Status::instance()->localized_status( array( $id => $this->get( 'STS_code' ) ), $plural, $schema );
61
-		return $code[ $id ];
58
+	function code($plural = FALSE, $schema = 'upper') {
59
+		$id = $this->get('STS_ID');
60
+		$code = EEM_Status::instance()->localized_status(array($id => $this->get('STS_code')), $plural, $schema);
61
+		return $code[$id];
62 62
 	}
63 63
 
64 64
 
@@ -68,8 +68,8 @@  discard block
 block discarded – undo
68 68
 	 * @param string $code
69 69
 	 * @return boolean
70 70
 	 */
71
-	function set_code( $code ) {
72
-		$this->set( 'STS_code', $code );
71
+	function set_code($code) {
72
+		$this->set('STS_code', $code);
73 73
 	}
74 74
 
75 75
 
@@ -79,7 +79,7 @@  discard block
 block discarded – undo
79 79
 	 * @return string
80 80
 	 */
81 81
 	function desc() {
82
-		return $this->get( 'STS_desc' );
82
+		return $this->get('STS_desc');
83 83
 	}
84 84
 
85 85
 
@@ -89,8 +89,8 @@  discard block
 block discarded – undo
89 89
 	 * @param string $desc
90 90
 	 * @return boolean
91 91
 	 */
92
-	function set_desc( $desc ) {
93
-		$this->set( 'STS_desc', $desc );
92
+	function set_desc($desc) {
93
+		$this->set('STS_desc', $desc);
94 94
 	}
95 95
 
96 96
 
@@ -100,7 +100,7 @@  discard block
 block discarded – undo
100 100
 	 * @return string
101 101
 	 */
102 102
 	function type() {
103
-		return $this->get( 'STS_type' );
103
+		return $this->get('STS_type');
104 104
 	}
105 105
 
106 106
 
@@ -110,8 +110,8 @@  discard block
 block discarded – undo
110 110
 	 * @param string $type
111 111
 	 * @return boolean
112 112
 	 */
113
-	function set_type( $type ) {
114
-		$this->set( 'STS_type', $type );
113
+	function set_type($type) {
114
+		$this->set('STS_type', $type);
115 115
 	}
116 116
 
117 117
 
@@ -121,7 +121,7 @@  discard block
 block discarded – undo
121 121
 	 * @return boolean
122 122
 	 */
123 123
 	function can_edit() {
124
-		return $this->get( 'STS_can_edit' );
124
+		return $this->get('STS_can_edit');
125 125
 	}
126 126
 
127 127
 
@@ -131,8 +131,8 @@  discard block
 block discarded – undo
131 131
 	 * @param boolean $can_edit
132 132
 	 * @return boolean
133 133
 	 */
134
-	function set_can_edit( $can_edit ) {
135
-		$this->set( 'STS_can_edit', $can_edit );
134
+	function set_can_edit($can_edit) {
135
+		$this->set('STS_can_edit', $can_edit);
136 136
 	}
137 137
 
138 138
 
@@ -142,7 +142,7 @@  discard block
 block discarded – undo
142 142
 	 * @return boolean
143 143
 	 */
144 144
 	function open() {
145
-		return $this->get( 'STS_open' );
145
+		return $this->get('STS_open');
146 146
 	}
147 147
 
148 148
 
@@ -152,8 +152,8 @@  discard block
 block discarded – undo
152 152
 	 * @param boolean $open
153 153
 	 * @return boolean
154 154
 	 */
155
-	function set_open( $open ) {
156
-		$this->set( 'STS_open', $open );
155
+	function set_open($open) {
156
+		$this->set('STS_open', $open);
157 157
 	}
158 158
 }
159 159
 
Please login to merge, or discard this patch.
Indentation   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -2,18 +2,18 @@
 block discarded – undo
2 2
 	exit( 'No direct script access allowed' );
3 3
 }
4 4
 /**
5
- * Event Espresso
6
- *
7
- * Event Registration and Management Plugin for WordPress
8
- *
9
- * @ package 		Event Espresso
10
- * @ author 		Event Espresso
11
- * @ copyright 	(c) 2008-2011 Event Espresso  All Rights Reserved.
12
- * @ license 		{@link http://eventespresso.com/support/terms-conditions/}   * see Plugin Licensing *
13
- * @ link 				{@link http://www.eventespresso.com}
14
- * @ since 			4.0
15
- *
16
- */
5
+	 * Event Espresso
6
+	 *
7
+	 * Event Registration and Management Plugin for WordPress
8
+	 *
9
+	 * @ package 		Event Espresso
10
+	 * @ author 		Event Espresso
11
+	 * @ copyright 	(c) 2008-2011 Event Espresso  All Rights Reserved.
12
+	 * @ license 		{@link http://eventespresso.com/support/terms-conditions/}   * see Plugin Licensing *
13
+	 * @ link 				{@link http://www.eventespresso.com}
14
+	 * @ since 			4.0
15
+	 *
16
+	 */
17 17
 
18 18
 
19 19
 
Please login to merge, or discard this patch.
Doc Comments   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -66,7 +66,7 @@  discard block
 block discarded – undo
66 66
 	/**
67 67
 	 * Sets code
68 68
 	 * @param string $code
69
-	 * @return boolean
69
+	 * @return boolean|null
70 70
 	 */
71 71
 	function set_code( $code ) {
72 72
 		$this->set( 'STS_code', $code );
@@ -87,7 +87,7 @@  discard block
 block discarded – undo
87 87
 	/**
88 88
 	 * Sets desc
89 89
 	 * @param string $desc
90
-	 * @return boolean
90
+	 * @return boolean|null
91 91
 	 */
92 92
 	function set_desc( $desc ) {
93 93
 		$this->set( 'STS_desc', $desc );
@@ -108,7 +108,7 @@  discard block
 block discarded – undo
108 108
 	/**
109 109
 	 * Sets type
110 110
 	 * @param string $type
111
-	 * @return boolean
111
+	 * @return boolean|null
112 112
 	 */
113 113
 	function set_type( $type ) {
114 114
 		$this->set( 'STS_type', $type );
@@ -129,7 +129,7 @@  discard block
 block discarded – undo
129 129
 	/**
130 130
 	 * Sets can_edit
131 131
 	 * @param boolean $can_edit
132
-	 * @return boolean
132
+	 * @return boolean|null
133 133
 	 */
134 134
 	function set_can_edit( $can_edit ) {
135 135
 		$this->set( 'STS_can_edit', $can_edit );
@@ -150,7 +150,7 @@  discard block
 block discarded – undo
150 150
 	/**
151 151
 	 * Sets open
152 152
 	 * @param boolean $open
153
-	 * @return boolean
153
+	 * @return boolean|null
154 154
 	 */
155 155
 	function set_open( $open ) {
156 156
 		$this->set( 'STS_open', $open );
Please login to merge, or discard this patch.
core/db_classes/EE_Taxes.class.php 3 patches
Indentation   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -2,12 +2,12 @@
 block discarded – undo
2 2
 	exit( 'No direct script access allowed' );
3 3
 }
4 4
 /**
5
- * Taxes class
6
- *
7
- * @package 			Event Espresso
8
- * @subpackage 	includes/classes/EE_Taxes.class.php
9
- * @author 				Brent Christensen
10
- */
5
+	 * Taxes class
6
+	 *
7
+	 * @package 			Event Espresso
8
+	 * @subpackage 	includes/classes/EE_Taxes.class.php
9
+	 * @author 				Brent Christensen
10
+	 */
11 11
 class EE_Taxes extends EE_BASE {
12 12
 
13 13
 	/**
Please login to merge, or discard this patch.
Braces   +3 added lines, -2 removed lines patch added patch discarded remove patch
@@ -36,8 +36,9 @@
 block discarded – undo
36 36
 		$tax = 0;
37 37
 		$total_tax = 0;
38 38
 		//This first checks to see if the given ticket is taxable.
39
-		if ( ! $ticket->get( 'TKT_taxable' ) )
40
-			return $tax;
39
+		if ( ! $ticket->get( 'TKT_taxable' ) ) {
40
+					return $tax;
41
+		}
41 42
 		//get subtotal (notice we're only retrieving a subtotal if there isn't one given)
42 43
 		$subtotal = self::get_subtotal_for_admin( $ticket );
43 44
 		//get taxes
Please login to merge, or discard this patch.
Spacing   +21 added lines, -21 removed lines patch added patch discarded remove patch
@@ -1,5 +1,5 @@  discard block
 block discarded – undo
1
-<?php if ( !defined( 'EVENT_ESPRESSO_VERSION' ) ) {
2
-	exit( 'No direct script access allowed' );
1
+<?php if ( ! defined('EVENT_ESPRESSO_VERSION')) {
2
+	exit('No direct script access allowed');
3 3
 }
4 4
 /**
5 5
  * Taxes class
@@ -32,20 +32,20 @@  discard block
 block discarded – undo
32 32
 	 * @param  EE_Ticket $ticket incoming EE_Ticket
33 33
 	 * @return float             total taxes to apply to ticket.
34 34
 	 */
35
-	public static function get_total_taxes_for_admin( EE_Ticket $ticket ) {
35
+	public static function get_total_taxes_for_admin(EE_Ticket $ticket) {
36 36
 		$tax = 0;
37 37
 		$total_tax = 0;
38 38
 		//This first checks to see if the given ticket is taxable.
39
-		if ( ! $ticket->get( 'TKT_taxable' ) )
39
+		if ( ! $ticket->get('TKT_taxable'))
40 40
 			return $tax;
41 41
 		//get subtotal (notice we're only retrieving a subtotal if there isn't one given)
42
-		$subtotal = self::get_subtotal_for_admin( $ticket );
42
+		$subtotal = self::get_subtotal_for_admin($ticket);
43 43
 		//get taxes
44 44
 		$taxes = self::get_taxes_for_admin();
45 45
 		//apply taxes to subtotal
46
-		foreach ( $taxes as $tax ) {
46
+		foreach ($taxes as $tax) {
47 47
 			//assuming taxes are not cumulative
48
-			$total_tax += $subtotal * $tax->get( 'PRC_amount' ) / 100;
48
+			$total_tax += $subtotal * $tax->get('PRC_amount') / 100;
49 49
 		}
50 50
 		return $total_tax;
51 51
 	}
@@ -57,8 +57,8 @@  discard block
 block discarded – undo
57 57
 	 */
58 58
 	public static function get_total_taxes_percentage() {
59 59
 		$total_tax_percent = 0;
60
-		foreach( self::get_taxes_for_admin() as $tax_price ) {
61
-			$total_tax_percent += $tax_price->get( 'PRC_amount' );
60
+		foreach (self::get_taxes_for_admin() as $tax_price) {
61
+			$total_tax_percent += $tax_price->get('PRC_amount');
62 62
 		}
63 63
 		return $total_tax_percent;
64 64
 	}
@@ -69,9 +69,9 @@  discard block
 block discarded – undo
69 69
 	 * @param EE_Ticket $ticket
70 70
 	 * @return float
71 71
 	 */
72
-	public static function get_subtotal_for_admin( EE_Ticket $ticket ) {
72
+	public static function get_subtotal_for_admin(EE_Ticket $ticket) {
73 73
 		$TKT_ID = $ticket->ID();
74
-		return isset( self::$_subtotal[ $TKT_ID ] ) ? self::$_subtotal[ $TKT_ID ] : self::_get_subtotal_for_admin( $ticket );
74
+		return isset(self::$_subtotal[$TKT_ID]) ? self::$_subtotal[$TKT_ID] : self::_get_subtotal_for_admin($ticket);
75 75
 	}
76 76
 
77 77
 
@@ -81,29 +81,29 @@  discard block
 block discarded – undo
81 81
 	 * @param  EE_Ticket $ticket
82 82
 	 * @return float     subtotal calculated from all EE_Price[] on Ticket.
83 83
 	 */
84
-	private static function _get_subtotal_for_admin( EE_Ticket $ticket ) {
84
+	private static function _get_subtotal_for_admin(EE_Ticket $ticket) {
85 85
 		$subtotal = 0;
86 86
 		//get all prices
87
-		$prices = $ticket->get_many_related( 'Price', array( 'default_where_conditions' => 'none', 'order_by' => array( 'PRC_order' => 'ASC' ) ) );
87
+		$prices = $ticket->get_many_related('Price', array('default_where_conditions' => 'none', 'order_by' => array('PRC_order' => 'ASC')));
88 88
 		//let's loop through them (base price is always the first item)
89
-		foreach ( $prices as $price ) {
90
-			if ( $price instanceof EE_Price ) {
89
+		foreach ($prices as $price) {
90
+			if ($price instanceof EE_Price) {
91 91
 				$price_type = $price->type_obj();
92
-				if ( $price_type instanceof EE_Price_Type ) {
93
-					switch ( $price->type_obj()->base_type() ) {
92
+				if ($price_type instanceof EE_Price_Type) {
93
+					switch ($price->type_obj()->base_type()) {
94 94
 						case 1: // base price
95 95
 						case 3: // surcharges
96
-							$subtotal += $price->is_percent() ? $subtotal * $price->get( 'PRC_amount' ) / 100 : $price->get( 'PRC_amount' );
96
+							$subtotal += $price->is_percent() ? $subtotal * $price->get('PRC_amount') / 100 : $price->get('PRC_amount');
97 97
 							break;
98 98
 						case 2: // discounts
99
-							$subtotal -= $price->is_percent() ? $subtotal * $price->get( 'PRC_amount' ) / 100 : $price->get( 'PRC_amount' );
99
+							$subtotal -= $price->is_percent() ? $subtotal * $price->get('PRC_amount') / 100 : $price->get('PRC_amount');
100 100
 							break;
101 101
 					}
102 102
 				}
103 103
 			}
104 104
 		}
105 105
 		$TKT_ID = $ticket->ID();
106
-		self::$_subtotal = array( $TKT_ID => $subtotal );
106
+		self::$_subtotal = array($TKT_ID => $subtotal);
107 107
 		return $subtotal;
108 108
 	}
109 109
 
@@ -114,7 +114,7 @@  discard block
 block discarded – undo
114 114
 	 * @return EE_Price[] EE_Price objects that have PRT_ID == 4
115 115
 	 */
116 116
 	public static function get_taxes_for_admin() {
117
-		self::$_default_taxes = ! empty( self::$_default_taxes ) ? self::$_default_taxes : EE_Registry::instance()->load_model( 'Price' )->get_all( array( array( 'Price_Type.PBT_ID' => 4 ) ) );
117
+		self::$_default_taxes = ! empty(self::$_default_taxes) ? self::$_default_taxes : EE_Registry::instance()->load_model('Price')->get_all(array(array('Price_Type.PBT_ID' => 4)));
118 118
 		return self::$_default_taxes;
119 119
 	}
120 120
 
Please login to merge, or discard this patch.
core/db_classes/EE_Term.class.php 3 patches
Spacing   +17 added lines, -17 removed lines patch added patch discarded remove patch
@@ -1,5 +1,5 @@  discard block
 block discarded – undo
1
-<?php if ( !defined( 'EVENT_ESPRESSO_VERSION' ) ) {
2
-	exit( 'No direct script access allowed' );
1
+<?php if ( ! defined('EVENT_ESPRESSO_VERSION')) {
2
+	exit('No direct script access allowed');
3 3
 }
4 4
 /**
5 5
  * Event Espresso
@@ -34,11 +34,11 @@  discard block
 block discarded – undo
34 34
 	 * @param bool $bydb
35 35
 	 * @param string $timezone
36 36
 	 */
37
-	protected function __construct( $fieldValues = array(), $bydb = FALSE, $timezone = '' ) {
38
-		if ( ! isset( $fieldValues[ 'slug' ] ) ) {
39
-			$fieldValues[ 'slug' ] = $fieldValues[ 'name' ];
37
+	protected function __construct($fieldValues = array(), $bydb = FALSE, $timezone = '') {
38
+		if ( ! isset($fieldValues['slug'])) {
39
+			$fieldValues['slug'] = $fieldValues['name'];
40 40
 		}
41
-		parent::__construct( $fieldValues, $bydb, $timezone );
41
+		parent::__construct($fieldValues, $bydb, $timezone);
42 42
 	}
43 43
 
44 44
 
@@ -47,9 +47,9 @@  discard block
 block discarded – undo
47 47
 	 * @param array $props_n_values
48 48
 	 * @return EE_Term|mixed
49 49
 	 */
50
-	public static function new_instance( $props_n_values = array() ) {
51
-		$has_object = parent::_check_for_object( $props_n_values, __CLASS__ );
52
-		return $has_object ? $has_object : new self( $props_n_values );
50
+	public static function new_instance($props_n_values = array()) {
51
+		$has_object = parent::_check_for_object($props_n_values, __CLASS__);
52
+		return $has_object ? $has_object : new self($props_n_values);
53 53
 	}
54 54
 
55 55
 
@@ -58,8 +58,8 @@  discard block
 block discarded – undo
58 58
 	 * @param array $props_n_values
59 59
 	 * @return EE_Term
60 60
 	 */
61
-	public static function new_instance_from_db( $props_n_values = array() ) {
62
-		return new self( $props_n_values, TRUE );
61
+	public static function new_instance_from_db($props_n_values = array()) {
62
+		return new self($props_n_values, TRUE);
63 63
 	}
64 64
 
65 65
 
@@ -69,7 +69,7 @@  discard block
 block discarded – undo
69 69
 	 * @return string
70 70
 	 */
71 71
 	function name() {
72
-		return $this->get( 'name' );
72
+		return $this->get('name');
73 73
 	}
74 74
 
75 75
 
@@ -79,8 +79,8 @@  discard block
 block discarded – undo
79 79
 	 * @param string $name
80 80
 	 * @return boolean
81 81
 	 */
82
-	function set_name( $name ) {
83
-		$this->set( 'name', $name );
82
+	function set_name($name) {
83
+		$this->set('name', $name);
84 84
 	}
85 85
 
86 86
 
@@ -90,7 +90,7 @@  discard block
 block discarded – undo
90 90
 	 * @return string
91 91
 	 */
92 92
 	function slug() {
93
-		return $this->get( 'slug' );
93
+		return $this->get('slug');
94 94
 	}
95 95
 
96 96
 
@@ -100,8 +100,8 @@  discard block
 block discarded – undo
100 100
 	 * @param string $slug
101 101
 	 * @return boolean
102 102
 	 */
103
-	function set_slug( $slug ) {
104
-		$this->set( 'slug', $slug );
103
+	function set_slug($slug) {
104
+		$this->set('slug', $slug);
105 105
 	}
106 106
 }
107 107
 
Please login to merge, or discard this patch.
Indentation   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -2,18 +2,18 @@
 block discarded – undo
2 2
 	exit( 'No direct script access allowed' );
3 3
 }
4 4
 /**
5
- * Event Espresso
6
- *
7
- * Event Registration and Management Plugin for WordPress
8
- *
9
- * @ package 		Event Espresso
10
- * @ author 		Event Espresso
11
- * @ copyright 	(c) 2008-2011 Event Espresso  All Rights Reserved.
12
- * @ license 		{@link http://eventespresso.com/support/terms-conditions/}   * see Plugin Licensing *
13
- * @ link 				{@link http://www.eventespresso.com}
14
- * @ since 			4.0
15
- *
16
- */
5
+	 * Event Espresso
6
+	 *
7
+	 * Event Registration and Management Plugin for WordPress
8
+	 *
9
+	 * @ package 		Event Espresso
10
+	 * @ author 		Event Espresso
11
+	 * @ copyright 	(c) 2008-2011 Event Espresso  All Rights Reserved.
12
+	 * @ license 		{@link http://eventespresso.com/support/terms-conditions/}   * see Plugin Licensing *
13
+	 * @ link 				{@link http://www.eventespresso.com}
14
+	 * @ since 			4.0
15
+	 *
16
+	 */
17 17
 
18 18
 
19 19
 
Please login to merge, or discard this patch.
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -42,7 +42,7 @@  discard block
 block discarded – undo
42 42
 
43 43
 
44 44
 	/**
45
-	 * @return boolean
45
+	 * @return boolean|null
46 46
 	 */
47 47
 	public function initialize_reg_step() {
48 48
 
@@ -169,7 +169,7 @@  discard block
 block discarded – undo
169 169
 
170 170
 
171 171
 	/**
172
-	 * @return boolean
172
+	 * @return boolean|null
173 173
 	 */
174 174
 	public function update_reg_step() {
175 175
 		EE_Error::doing_it_wrong( __CLASS__ . '::' . __FILE__, __( 'Can not call update_reg_step() on the Finalize Registration reg step.', 'event_espresso'), '4.6.0' );
Please login to merge, or discard this patch.
core/db_classes/EE_Term_Relationship.class.php 2 patches
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -1,5 +1,5 @@  discard block
 block discarded – undo
1
-<?php if ( !defined( 'EVENT_ESPRESSO_VERSION' ) ) {
2
-	exit( 'No direct script access allowed' );
1
+<?php if ( ! defined('EVENT_ESPRESSO_VERSION')) {
2
+	exit('No direct script access allowed');
3 3
 }
4 4
 /**
5 5
  * Event Espresso
@@ -30,9 +30,9 @@  discard block
 block discarded – undo
30 30
 	 * @param array $props_n_values
31 31
 	 * @return EE_Term_Relationship
32 32
 	 */
33
-	public static function new_instance( $props_n_values = array() ) {
34
-		$has_object = parent::_check_for_object( $props_n_values, __CLASS__ );
35
-		return $has_object ? $has_object : new self( $props_n_values );
33
+	public static function new_instance($props_n_values = array()) {
34
+		$has_object = parent::_check_for_object($props_n_values, __CLASS__);
35
+		return $has_object ? $has_object : new self($props_n_values);
36 36
 	}
37 37
 
38 38
 
@@ -41,8 +41,8 @@  discard block
 block discarded – undo
41 41
 	 * @param array $props_n_values
42 42
 	 * @return EE_Term_Relationship
43 43
 	 */
44
-	public static function new_instance_from_db( $props_n_values = array() ) {
45
-		return new self( $props_n_values, TRUE );
44
+	public static function new_instance_from_db($props_n_values = array()) {
45
+		return new self($props_n_values, TRUE);
46 46
 	}
47 47
 
48 48
 
Please login to merge, or discard this patch.
Indentation   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -2,18 +2,18 @@
 block discarded – undo
2 2
 	exit( 'No direct script access allowed' );
3 3
 }
4 4
 /**
5
- * Event Espresso
6
- *
7
- * Event Registration and Management Plugin for WordPress
8
- *
9
- * @ package 		Event Espresso
10
- * @ author 		Event Espresso
11
- * @ copyright 	(c) 2008-2011 Event Espresso  All Rights Reserved.
12
- * @ license 		{@link http://eventespresso.com/support/terms-conditions/}   * see Plugin Licensing *
13
- * @ link 				{@link http://www.eventespresso.com}
14
- * @ since 			4.0
15
- *
16
- */
5
+	 * Event Espresso
6
+	 *
7
+	 * Event Registration and Management Plugin for WordPress
8
+	 *
9
+	 * @ package 		Event Espresso
10
+	 * @ author 		Event Espresso
11
+	 * @ copyright 	(c) 2008-2011 Event Espresso  All Rights Reserved.
12
+	 * @ license 		{@link http://eventespresso.com/support/terms-conditions/}   * see Plugin Licensing *
13
+	 * @ link 				{@link http://www.eventespresso.com}
14
+	 * @ since 			4.0
15
+	 *
16
+	 */
17 17
 
18 18
 
19 19
 
Please login to merge, or discard this patch.
core/db_classes/EE_Term_Taxonomy.class.php 3 patches
Spacing   +14 added lines, -14 removed lines patch added patch discarded remove patch
@@ -1,5 +1,5 @@  discard block
 block discarded – undo
1
-<?php if ( !defined( 'EVENT_ESPRESSO_VERSION' ) ) {
2
-	exit( 'No direct script access allowed' );
1
+<?php if ( ! defined('EVENT_ESPRESSO_VERSION')) {
2
+	exit('No direct script access allowed');
3 3
 }
4 4
 /**
5 5
  * Event Espresso
@@ -32,9 +32,9 @@  discard block
 block discarded – undo
32 32
 	 * @param array $props_n_values
33 33
 	 * @return EE_Term_Taxonomy
34 34
 	 */
35
-	public static function new_instance( $props_n_values = array() ) {
36
-		$has_object = parent::_check_for_object( $props_n_values, __CLASS__ );
37
-		return $has_object ? $has_object : new self( $props_n_values );
35
+	public static function new_instance($props_n_values = array()) {
36
+		$has_object = parent::_check_for_object($props_n_values, __CLASS__);
37
+		return $has_object ? $has_object : new self($props_n_values);
38 38
 	}
39 39
 
40 40
 
@@ -43,8 +43,8 @@  discard block
 block discarded – undo
43 43
 	 * @param array $props_n_values
44 44
 	 * @return EE_Term_Taxonomy
45 45
 	 */
46
-	public static function new_instance_from_db( $props_n_values = array() ) {
47
-		return new self( $props_n_values, TRUE );
46
+	public static function new_instance_from_db($props_n_values = array()) {
47
+		return new self($props_n_values, TRUE);
48 48
 	}
49 49
 
50 50
 
@@ -54,7 +54,7 @@  discard block
 block discarded – undo
54 54
 	 * @return string
55 55
 	 */
56 56
 	function taxonomy() {
57
-		return $this->get( 'taxonomy' );
57
+		return $this->get('taxonomy');
58 58
 	}
59 59
 
60 60
 
@@ -64,8 +64,8 @@  discard block
 block discarded – undo
64 64
 	 * @param string $taxonomy
65 65
 	 * @return boolean
66 66
 	 */
67
-	function set_taxonomy( $taxonomy ) {
68
-		$this->set( 'taxonomy', $taxonomy );
67
+	function set_taxonomy($taxonomy) {
68
+		$this->set('taxonomy', $taxonomy);
69 69
 	}
70 70
 
71 71
 
@@ -75,7 +75,7 @@  discard block
 block discarded – undo
75 75
 	 * @return int
76 76
 	 */
77 77
 	function count() {
78
-		return $this->get( 'term_count' );
78
+		return $this->get('term_count');
79 79
 	}
80 80
 
81 81
 
@@ -85,8 +85,8 @@  discard block
 block discarded – undo
85 85
 	 * @param int $term_count
86 86
 	 * @return boolean
87 87
 	 */
88
-	function set_count( $term_count ) {
89
-		$this->set( 'term_count', $term_count );
88
+	function set_count($term_count) {
89
+		$this->set('term_count', $term_count);
90 90
 	}
91 91
 
92 92
 
@@ -96,7 +96,7 @@  discard block
 block discarded – undo
96 96
 	 * @return EE_Term
97 97
 	 */
98 98
 	function term() {
99
-		return $this->get_first_related( 'Term' );
99
+		return $this->get_first_related('Term');
100 100
 	}
101 101
 
102 102
 
Please login to merge, or discard this patch.
Indentation   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -2,18 +2,18 @@
 block discarded – undo
2 2
 	exit( 'No direct script access allowed' );
3 3
 }
4 4
 /**
5
- * Event Espresso
6
- *
7
- * Event Registration and Management Plugin for WordPress
8
- *
9
- * @ package 		Event Espresso
10
- * @ author 		Event Espresso
11
- * @ copyright 	(c) 2008-2011 Event Espresso  All Rights Reserved.
12
- * @ license 		{@link http://eventespresso.com/support/terms-conditions/}   * see Plugin Licensing *
13
- * @ link 				{@link http://www.eventespresso.com}
14
- * @ since 			4.0
15
- *
16
- */
5
+	 * Event Espresso
6
+	 *
7
+	 * Event Registration and Management Plugin for WordPress
8
+	 *
9
+	 * @ package 		Event Espresso
10
+	 * @ author 		Event Espresso
11
+	 * @ copyright 	(c) 2008-2011 Event Espresso  All Rights Reserved.
12
+	 * @ license 		{@link http://eventespresso.com/support/terms-conditions/}   * see Plugin Licensing *
13
+	 * @ link 				{@link http://www.eventespresso.com}
14
+	 * @ since 			4.0
15
+	 *
16
+	 */
17 17
 
18 18
 
19 19
 
Please login to merge, or discard this patch.
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -42,7 +42,7 @@  discard block
 block discarded – undo
42 42
 
43 43
 
44 44
 	/**
45
-	 * @return boolean
45
+	 * @return boolean|null
46 46
 	 */
47 47
 	public function initialize_reg_step() {
48 48
 
@@ -169,7 +169,7 @@  discard block
 block discarded – undo
169 169
 
170 170
 
171 171
 	/**
172
-	 * @return boolean
172
+	 * @return boolean|null
173 173
 	 */
174 174
 	public function update_reg_step() {
175 175
 		EE_Error::doing_it_wrong( __CLASS__ . '::' . __FILE__, __( 'Can not call update_reg_step() on the Finalize Registration reg step.', 'event_espresso'), '4.6.0' );
Please login to merge, or discard this patch.
core/db_classes/EE_Ticket_Template.class.php 2 patches
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -1,5 +1,5 @@  discard block
 block discarded – undo
1
-<?php if ( ! defined( 'EVENT_ESPRESSO_VERSION' ) ) {
2
-	exit( 'No direct script access allowed' );
1
+<?php if ( ! defined('EVENT_ESPRESSO_VERSION')) {
2
+	exit('No direct script access allowed');
3 3
 }
4 4
 /**
5 5
  * Event Espresso
@@ -35,9 +35,9 @@  discard block
 block discarded – undo
35 35
 	 * @param string $timezone
36 36
 	 * @return EE_Ticket_Template|mixed
37 37
 	 */
38
-	public static function new_instance( $props_n_values = array(), $timezone = '' ) {
39
-		$has_object = parent::_check_for_object( $props_n_values, __CLASS__, $timezone );
40
-		return $has_object ? $has_object : new self( $props_n_values, FALSE, $timezone );
38
+	public static function new_instance($props_n_values = array(), $timezone = '') {
39
+		$has_object = parent::_check_for_object($props_n_values, __CLASS__, $timezone);
40
+		return $has_object ? $has_object : new self($props_n_values, FALSE, $timezone);
41 41
 	}
42 42
 
43 43
 
@@ -47,8 +47,8 @@  discard block
 block discarded – undo
47 47
 	 * @param string $timezone
48 48
 	 * @return EE_Ticket_Template
49 49
 	 */
50
-	public static function new_instance_from_db( $props_n_values = array(), $timezone = '' ) {
51
-		return new self( $props_n_values, TRUE, $timezone );
50
+	public static function new_instance_from_db($props_n_values = array(), $timezone = '') {
51
+		return new self($props_n_values, TRUE, $timezone);
52 52
 	}
53 53
 
54 54
 
Please login to merge, or discard this patch.
Indentation   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -2,18 +2,18 @@
 block discarded – undo
2 2
 	exit( 'No direct script access allowed' );
3 3
 }
4 4
 /**
5
- * Event Espresso
6
- *
7
- * Event Registration and Management Plugin for WordPress
8
- *
9
- * @ package        Event Espresso
10
- * @ author        Event Espresso
11
- * @ copyright    (c) 2008-2011 Event Espresso  All Rights Reserved.
12
- * @ license        {@link http://eventespresso.com/support/terms-conditions/}   * see Plugin Licensing *
13
- * @ link                {@link http://www.eventespresso.com}
14
- * @ since            4.0
15
- *
16
- */
5
+	 * Event Espresso
6
+	 *
7
+	 * Event Registration and Management Plugin for WordPress
8
+	 *
9
+	 * @ package        Event Espresso
10
+	 * @ author        Event Espresso
11
+	 * @ copyright    (c) 2008-2011 Event Espresso  All Rights Reserved.
12
+	 * @ license        {@link http://eventespresso.com/support/terms-conditions/}   * see Plugin Licensing *
13
+	 * @ link                {@link http://www.eventespresso.com}
14
+	 * @ since            4.0
15
+	 *
16
+	 */
17 17
 
18 18
 
19 19
 
Please login to merge, or discard this patch.