Issues (850)

Security Analysis    4 potential vulnerabilities

This project does not seem to handle request data directly as such no vulnerable execution paths were found.

  File Inclusion
File Inclusion enables an attacker to inject custom files into PHP's file loading mechanism, either explicitly passed to include, or for example via PHP's auto-loading mechanism.
  Regex Injection
Regex Injection enables an attacker to execute arbitrary code in your PHP process.
  SQL Injection
SQL Injection enables an attacker to execute arbitrary SQL code on your database server gaining access to user data, or manipulating user data.
  Response Splitting
Response Splitting can be used to send arbitrary responses.
  File Manipulation
File Manipulation enables an attacker to write custom data to files. This potentially leads to injection of arbitrary code on the server.
  Object Injection
Object Injection enables an attacker to inject an object into PHP code, and can lead to arbitrary code execution, file exposure, or file manipulation attacks.
  File Exposure
File Exposure allows an attacker to gain access to local files that he should not be able to access. These files can for example include database credentials, or other configuration files.
  XML Injection
XML Injection enables an attacker to read files on your local filesystem including configuration files, or can be abused to freeze your web-server process.
  Code Injection (1)
Code Injection enables an attacker to execute arbitrary code on the server.
  Variable Injection (2)
Variable Injection enables an attacker to overwrite program variables with custom data, and can lead to further vulnerabilities.
  XPath Injection
XPath Injection enables an attacker to modify the parts of XML document that are read. If that XML document is for example used for authentication, this can lead to further vulnerabilities similar to SQL Injection.
  Other Vulnerability
This category comprises other attack vectors such as manipulating the PHP runtime, loading custom extensions, freezing the runtime, or similar.
  Command Injection
Command Injection enables an attacker to inject a shell command that is execute with the privileges of the web-server. This can be used to expose sensitive data, or gain access of your server.
  LDAP Injection
LDAP Injection enables an attacker to inject LDAP statements potentially granting permission to run unauthorized queries, or modify content inside the LDAP tree.
  Cross-Site Scripting (1)
Cross-Site Scripting enables an attacker to inject code into the response of a web-request that is viewed by other users. It can for example be used to bypass access controls, or even to take over other users' accounts.
  Header Injection
Unfortunately, the security analysis is currently not available for your project. If you are a non-commercial open-source project, please contact support to gain access.

includes/deprecated-functions.php (5 issues)

Code
1
<?php
2
/**
3
 * Contains all deprecated functions.
4
 *
5
 * @since 1.0.19
6
 * @package Invoicing
7
 */
8
9
defined( 'ABSPATH' ) || exit;
10
11
/**
12
 * @deprecated
13
 */
14
function wpinv_get_invoice_cart_id() {
15
    return getpaid_get_current_invoice_id();
16
}
17
18
/**
19
 * @deprecated
20
 */
21
function wpinv_get_invoice_cart() {
22
    return wpinv_get_invoice( getpaid_get_current_invoice_id() );
23
}
24
25
/**
26
 * @deprecated
27
 */
28
function wpinv_get_invoice_description( $invoice ) {
29
    $invoice = new WPInv_Invoice( $invoice );
30
    return $invoice->get_description();
31
}
32
33
/**
34
 * @deprecated
35
 */
36
function wpinv_get_invoice_currency_code( $invoice ) {
37
    $invoice = new WPInv_Invoice( $invoice );
38
    return $invoice->get_currency();
39
}
40
41
/**
42
 * @deprecated
43
 */
44
function wpinv_get_payment_user_email( $invoice ) {
45
    $invoice = new WPInv_Invoice( $invoice );
46
    return $invoice->get_email();
47
}
48
49
/**
50
 * @deprecated
51
 */
52
function wpinv_get_user_id( $invoice ) {
53
    $invoice = new WPInv_Invoice( $invoice );
54
    return $invoice->get_user_id();
55
}
56
57
/**
58
 * @deprecated
59
 */
60
function wpinv_get_invoice_status( $invoice, $return_label = false ) {
61
    $invoice = new WPInv_Invoice( $invoice );
62
63
    if ( $return_label ) {
64
        return $invoice->get_status_nicename();
65
    }
66
67
    return $invoice->get_status();
68
}
69
70
/**
71
 * @deprecated
72
 */
73
function wpinv_get_payment_gateway( $invoice, $return_label = false ) {
74
    $invoice = new WPInv_Invoice( $invoice );
75
76
    if ( $return_label ) {
77
        return $invoice->get_gateway_title();
78
    }
79
80
    return $invoice->get_gateway();
81
}
82
83
/**
84
 * @deprecated
85
 */
86
function wpinv_get_payment_gateway_name( $invoice ) {
87
    return wpinv_get_payment_gateway( $invoice, true );
0 ignored issues
show
Deprecated Code introduced by
The function wpinv_get_payment_gateway() has been deprecated. ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-deprecated  annotation

87
    return /** @scrutinizer ignore-deprecated */ wpinv_get_payment_gateway( $invoice, true );
Loading history...
88
}
89
90
/**
91
 * @deprecated
92
 */
93
function wpinv_get_payment_transaction_id( $invoice ) {
94
    $invoice = new WPInv_Invoice( $invoice );
95
    return $invoice->get_transaction_id();
96
}
97
98
/**
99
 * @deprecated
100
 */
101
function wpinv_get_invoice_meta( $invoice_id = 0, $meta_key = '_wpinv_payment_meta', $single = true ) {
102
    $invoice = new WPInv_Invoice( $invoice_id );
103
    return $invoice->get_meta( $meta_key, $single );
104
}
105
106
/**
107
 * @deprecated
108
 */
109
function wpinv_update_invoice_meta( $invoice_id = 0, $meta_key = '', $meta_value = '' ) {
110
    $invoice = new WPInv_Invoice( $invoice_id );
111
    return $invoice->update_meta_data( $meta_key, $meta_value );
112
}
113
114
/**
115
 * @deprecated
116
 */
117
function wpinv_get_items( $invoice = 0 ) {
118
    $invoice = new WPInv_Invoice( $invoice );
119
    return $invoice->get_items();
120
}
121
122
/**
123
 * @deprecated
124
 */
125
function wpinv_get_fees( $invoice = 0 ) {
126
    $invoice = new WPInv_Invoice( $invoice );
127
    return $invoice->get_fees();
128
}
129
130
/**
131
 * @deprecated
132
 */
133
function wpinv_get_invoice_ip( $invoice ) {
134
    $invoice = new WPInv_Invoice( $invoice );
135
    return $invoice->get_ip();
136
}
137
138
/**
139
 * @deprecated
140
 */
141
function wpinv_get_invoice_user_info( $invoice ) {
142
    $invoice = new WPInv_Invoice( $invoice );
143
    return $invoice->get_user_info();
144
}
145
146
/**
147
 * @deprecated
148
 */
149
function wpinv_subtotal( $invoice = 0, $currency = false ) {
150
    $invoice  = new WPInv_Invoice( $invoice );
151
    $subtotal = $invoice->get_subtotal();
152
153
    if ( $currency ) {
154
        return wpinv_price( $subtotal, $invoice->get_currency() );
155
    }
156
157
    return $subtotal;
158
}
159
160
/**
161
 * @deprecated
162
 */
163
function wpinv_tax( $invoice = 0, $currency = false ) {
164
    $invoice  = new WPInv_Invoice( $invoice );
165
    $tax      = $invoice->get_total_tax();
166
167
    if ( $currency ) {
168
        return wpinv_price( $tax, $invoice->get_currency() );
169
    }
170
171
    return $tax;
172
}
173
174
/**
175
 * @deprecated
176
 */
177
function wpinv_discount( $invoice = 0, $currency = false ) {
178
    $invoice  = new WPInv_Invoice( $invoice );
179
    $discount = $invoice->get_total_discount();
180
181
    if ( $currency ) {
182
        return wpinv_price( $discount, $invoice->get_currency() );
183
    }
184
185
    return $discount;
186
}
187
188
/**
189
 * @deprecated
190
 */
191
function wpinv_discount_code( $invoice = 0 ) {
192
    $invoice = new WPInv_Invoice( $invoice );
193
    return $invoice->get_discount_code();
194
}
195
196
/**
197
 * @deprecated
198
 */
199
function wpinv_payment_total( $invoice = 0, $currency = false ) {
200
    $invoice  = new WPInv_Invoice( $invoice );
201
    $total = $invoice->get_total();
202
203
    if ( $currency ) {
204
        return wpinv_price( $total, $invoice->get_currency() );
205
    }
206
207
    return $total;
208
}
209
210
/**
211
 * @deprecated
212
 */
213
function wpinv_get_date_created( $invoice = 0, $format = '' ) {
214
    $invoice = new WPInv_Invoice( $invoice );
215
216
    $format         = ! empty( $format ) ? $format : get_option( 'date_format' );
217
    $date_created   = $invoice->get_created_date();
218
219
    return empty( $date_created ) ? date_i18n( $format, strtotime( $date_created ) ) : '';
0 ignored issues
show
It seems like $format can also be of type false; however, parameter $format of date_i18n() does only seem to accept string, maybe add an additional type check? ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-type  annotation

219
    return empty( $date_created ) ? date_i18n( /** @scrutinizer ignore-type */ $format, strtotime( $date_created ) ) : '';
Loading history...
220
}
221
222
/**
223
 * @deprecated
224
 */
225
function wpinv_get_invoice_date( $invoice = 0, $format = '' ) {
226
    wpinv_get_date_created( $invoice, $format );
0 ignored issues
show
Deprecated Code introduced by
The function wpinv_get_date_created() has been deprecated. ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-deprecated  annotation

226
    /** @scrutinizer ignore-deprecated */ wpinv_get_date_created( $invoice, $format );
Loading history...
227
}
228
229
/**
230
 * @deprecated
231
 */
232
function wpinv_get_invoice_vat_number( $invoice = 0 ) {
233
    $invoice = new WPInv_Invoice( $invoice );
234
    return $invoice->get_vat_number();
235
}
236
237
/**
238
 * @deprecated
239
 */
240
function wpinv_insert_payment_note( $invoice = 0, $note = '', $user_type = false, $added_by_user = false, $system = false ) {
241
    $invoice = new WPInv_Invoice( $invoice );
242
    return $invoice->add_note( $note, $user_type, $added_by_user, $system );
243
}
244
245
/**
246
 * @deprecated
247
 */
248
function wpinv_get_payment_key( $invoice = 0 ) {
249
	$invoice = new WPInv_Invoice( $invoice );
250
    return $invoice->get_key();
251
}
252
253
/**
254
 * @deprecated
255
 */
256
function wpinv_get_invoice_number( $invoice = 0 ) {
257
    $invoice = new WPInv_Invoice( $invoice );
258
    return $invoice->get_number();
259
}
260
261
/**
262
 * @deprecated
263
 */
264
function wpinv_get_cart_discountable_subtotal() {
265
    return 0;
266
}
267
268
/**
269
 * @deprecated
270
 */
271
function wpinv_get_cart_items_subtotal() {
272
    return 0;
273
}
274
275
/**
276
 * @deprecated
277
 */
278
function wpinv_get_cart_subtotal() {
279
    return 0;
280
}
281
282
/**
283
 * @deprecated
284
 */
285
function wpinv_cart_subtotal() {
286
    return 0;
287
}
288
289
/**
290
 * @deprecated
291
 */
292
function wpinv_get_cart_total() {
293
    return 0;
294
}
295
296
/**
297
 * @deprecated
298
 */
299
function wpinv_cart_total() {
300
    return 0;
301
}
302
303
/**
304
 * @deprecated
305
 */
306
function wpinv_get_cart_tax() {
307
    return 0;
308
}
309
310
/**
311
 * @deprecated
312
 */
313
function wpinv_cart_tax() {
314
    return 0;
315
}
316
317
/**
318
 * @deprecated
319
 */
320
function wpinv_get_cart_discount_code() {
321
    return '';
322
}
323
324
/**
325
 * @deprecated
326
 */
327
function wpinv_cart_discount_code() {
328
    return '';
329
}
330
331
/**
332
 * @deprecated
333
 */
334
function wpinv_get_cart_discount() {
335
    return 0;
336
}
337
338
/**
339
 * @deprecated
340
 */
341
function wpinv_cart_discount() {
342
    return '';
343
}
344
345
/**
346
 * @deprecated
347
 */
348
function wpinv_get_cart_fees() {
349
    return array();
350
}
351
352
/**
353
 * @deprecated
354
 */
355
function wpinv_get_cart_fee_total() {
356
    return 0;
357
}
358
359
/**
360
 * @deprecated
361
 */
362
function wpinv_get_cart_fee_tax() {
363
    return 0;
364
}
365
366
/**
367
 * @deprecated
368
 */
369
function wpinv_cart_has_recurring_item() {
370
    return false;
371
}
372
373
/**
374
 * @deprecated
375
 */
376
function wpinv_cart_has_free_trial() {
377
    return false;
378
}
379
380
/**
381
 * @deprecated
382
 */
383
function wpinv_get_cart_contents() {
384
    return array();
385
}
386
387
/**
388
 * @deprecated
389
 */
390
function wpinv_get_cart_content_details() {
391
    return array();
392
}
393
394
/**
395
 * @deprecated
396
 */
397
function wpinv_get_cart_details() {
398
    return array();
399
}
400
401
/**
402
 * @deprecated
403
 */
404
function wpinv_update_payment_status( $invoice, $new_status = 'publish' ) {
405
    $invoice = new WPInv_Invoice( $invoice );
406
    return $invoice->update_status( $new_status );
407
}
408
409
/**
410
 * @deprecated
411
 */
412
function wpinv_cart_has_fees() {
413
    return false;
414
}
415
416
/**
417
 * @deprecated
418
 */
419
function wpinv_set_checkout_session() {
420
    return false;
421
}
422
423
/**
424
 * @deprecated
425
 */
426
function wpinv_get_checkout_session() {
427
	return false;
428
}
429
430
/**
431
 * @deprecated
432
 */
433
function wpinv_empty_cart() {
434
    return false;
435
}
436
437
/**
438
 * @deprecated
439
 */
440
function wpinv_display_invoice_totals() {}
441
442
/**
443
 * @deprecated
444
 */
445
function wpinv_checkout_billing_details() {
446
    return array();
447
}
448
449
/**
450
 * @deprecated
451
 */
452
function wpinv_register_post_types() {
453
    GetPaid_Post_Types::register_post_types();
454
}
455
456
/**
457
 * @deprecated
458
 */
459
function wpinv_set_payment_transaction_id( $invoice_id = 0, $transaction_id = '' ) {
460
461
    // Fetch the invoice.
462
    $invoice = new WPInv_Invoice( $invoice_id );
463
464
    if ( 0 == $invoice->get_id() ) {
465
        return false;
466
    }
467
468
    // Prepare the transaction id.
469
    if ( empty( $transaction_id ) ) {
470
        $transaction_id = $invoice_id;
471
    }
472
473
    // Set the transaction id;
474
    $invoice->set_transaction_id( apply_filters( 'wpinv_set_payment_transaction_id', $transaction_id, $invoice ) );
475
476
    // Save the invoice.
477
    return $invoice->save();
478
}
479
480
/**
481
 * @deprecated
482
 *
483
 * @param string $gateway
484
 * @param WPInv_Invoice $invoice
485
 * @param string $gateway
486
 */
487
function wpinv_send_to_gateway( $gateway, $invoice ) {
488
489
    $payment_data = array(
490
        'invoice_id'     => $invoice->get_id(),
491
        'items'          => $invoice->get_cart_details(),
492
        'cart_discounts' => array( $invoice->get_discount_code() ),
493
        'fees'           => $invoice->get_total_fees(),
494
        'subtotal'       => $invoice->get_subtotal(),
495
        'discount'       => $invoice->get_total_discount(),
496
        'tax'            => $invoice->get_total_tax(),
497
        'price'          => $invoice->get_total(),
498
        'invoice_key'    => $invoice->get_key(),
499
        'user_email'     => $invoice->get_email(),
500
        'date'           => gmdate( 'Y-m-d H:i:s', time() ),
501
        'user_info'      => $invoice->get_user_info(),
502
        'post_data'      => wp_kses_post_deep( wp_unslash( $_POST ) ),
503
        'cart_details'   => $invoice->get_cart_details(),
504
        'gateway'        => $gateway,
505
        'card_info'      => array(),
506
        'gateway_nonce'  => wp_create_nonce( 'wpi-gateway' ),
507
    );
508
509
    do_action( 'wpinv_gateway_' . $gateway, $payment_data );
510
}
511
512
/**
513
 * @deprecated
514
 */
515
function wpinv_die_handler() {
516
    die();
0 ignored issues
show
Using exit here is not recommended.

In general, usage of exit should be done with care and only when running in a scripting context like a CLI script.

Loading history...
517
}
518
519
/**
520
 * @deprecated
521
 */
522
function wpinv_die( $message = '', $title = '', $status = 400 ) {
523
    add_filter( 'wp_die_ajax_handler', 'wpinv_die_handler', 10, 3 );
524
    add_filter( 'wp_die_handler', 'wpinv_die_handler', 10, 3 );
525
    wp_die( esc_html( $message ), esc_html( $title ), array( 'response' => (int) $status ) );
526
}
527
528
/**
529
 * @deprecated
530
 */
531
function wpinv_checkout_cart_columns() {
532
    return 4;
533
}
534
535
/**
536
 * @deprecated
537
 */
538
function wpinv_set_cart_discount() {
539
    return array();
540
}
541
542
/**
543
 * @deprecated
544
 */
545
function wpinv_unset_cart_discount() {
546
    return array();
547
}
548
549
/**
550
 * @deprecated
551
 */
552
function wpinv_cart_discounts_html() {}
553
554
/**
555
 * @deprecated
556
 */
557
function wpinv_get_cart_discounts_html() {}
558
559
/**
560
 * @deprecated
561
 */
562
function wpinv_display_cart_discount() {}
563
564
/**
565
 * @deprecated
566
 */
567
function wpinv_multiple_discounts_allowed() {
568
    return false;
569
}
570
571
/**
572
 * @deprecated
573
 */
574
function wpinv_get_cart_items_discount_amount() {
575
    return 0;
576
}
577
578
/**
579
 * @deprecated
580
 */
581
function wpinv_get_cart_item_discount_amount() {
582
    return 0;
583
}
584
585
/**
586
 * @deprecated.
587
 */
588
function wpinv_new_invoice_notification() {}
589
590
/**
591
 * @deprecated.
592
 */
593
function wpinv_cancelled_invoice_notification() {}
594
595
/**
596
 * @deprecated.
597
 */
598
function wpinv_failed_invoice_notification() {}
599
600
/**
601
 * @deprecated.
602
 */
603
function wpinv_onhold_invoice_notification() {}
604
605
/**
606
 * @deprecated.
607
 */
608
function wpinv_processing_invoice_notification() {}
609
610
/**
611
 * @deprecated.
612
 */
613
function wpinv_completed_invoice_notification() {}
614
615
/**
616
 * @deprecated.
617
 */
618
function wpinv_fully_refunded_notification() {}
619
620
/**
621
 * @deprecated.
622
 */
623
function wpinv_partially_refunded_notification() {}
624
625
/**
626
 * @deprecated
627
 */
628
function wpinv_new_invoice_note_notification() {}
629
630
/**
631
 * @deprecated
632
 */
633
function wpinv_user_invoice_notification() {}
634
635
/**
636
 * @deprecated
637
 */
638
function wpinv_user_note_notification() {}
639
640
/**
641
 * @deprecated
642
 */
643
function wpinv_invoice_status_label( $status, $status_display = '' ) {
644
    return empty( $status_display ) ? sanitize_text_field( $status ) : sanitize_text_field( $status_display );
645
}
646
647
/**
648
 * @deprecated
649
 */
650
function wpinv_clean_invoice_number( $number ) {
651
    return $number;
652
}
653
654
/**
655
 * @deprecated
656
 */
657
function wpinv_update_invoice_number() {}
658
659
/**
660
 * @deprecated
661
 */
662
function wpinv_invoice_subscription_details() {}
663
664
/**
665
 * @deprecated
666
 */
667
function wpinv_schedule_events() {}
668
669
/**
670
 * @deprecated
671
 */
672
function wpinv_email_payment_reminders() {}
673
674
/**
675
 * @deprecated
676
 */
677
function wpinv_send_overdue_reminder() {}
678
679
/**
680
 * @deprecated
681
 */
682
function wpinv_send_customer_note_email() {}
683
684
/**
685
 * @deprecated
686
 */
687
function wpinv_send_payment_reminder_notification() {}
688
689
/**
690
 * @deprecated
691
 */
692
function wpinv_payment_reminder_sent() {}
693
694
/**
695
 * @deprecated
696
 */
697
function wpinv_send_pre_payment_reminder_notification() {}
698
699
/**
700
 * @deprecated
701
 */
702
function wpinv_email_renewal_reminders() {}
703
704
/**
705
 * @deprecated
706
 */
707
function wpinv_send_customer_invoice() {}
708
709
/**
710
 * @deprecated
711
 */
712
function wpinv_process_checkout() {}
713
714
/**
715
 * @deprecated
716
 */
717
function wpinv_checkout_validate_current_user() {}
718
719
/**
720
 * @deprecated
721
 */
722
function wpinv_checkout_validate_invoice_user() {}
723
724
/**
725
 * @deprecated
726
 */
727
function wpinv_checkout_validate_agree_to_terms() {}
728
729
/**
730
 * @deprecated
731
 */
732
function wpinv_checkout_validate_cc_zip() {}
733
734
/**
735
 * @deprecated
736
 */
737
function wpinv_checkout_validate_gateway() {}
738
739
/**
740
 * @deprecated
741
 */
742
function wpinv_show_gateways() {
743
    return true;
744
}
745
746
/**
747
 * @deprecated
748
 */
749
function wpinv_shop_supports_buy_now() {
750
    return true;
751
}
752
753
/**
754
 * @deprecated
755
 */
756
function wpinv_gateway_supports_buy_now() {
757
    return true;
758
}
759
760
/**
761
 * @deprecated
762
 */
763
function wpinv_is_ajax_disabled() {
764
    return false;
765
}
766
767
/**
768
 * @deprecated
769
 */
770
function wpinv_remove_item_logs_on_delete() {}
771
772
/**
773
 * @deprecated
774
 */
775
function wpinv_record_item_in_log() {}
776
777
/**
778
 * @deprecated
779
 */
780
function wpinv_check_delete_item() {
781
    return true;
782
}
783
784
/**
785
 * @deprecated
786
 */
787
function wpinv_admin_action_delete() {}
788
789
/**
790
 * @deprecated
791
 */
792
function wpinv_can_delete_item() {
793
    return wpinv_current_user_can_manage_invoicing();
794
}
795
796
/**
797
 * @deprecated
798
 */
799
function wpinv_item_in_use() {
800
    return false;
801
}
802
803
/**
804
 * @deprecated
805
 */
806
function wpinv_has_variable_prices() {
807
    return false;
808
}
809
810
/**
811
 * @deprecated
812
 */
813
function wpinv_get_item_position_in_cart() {
814
    return 1;
815
}
816
817
/**
818
 * @deprecated
819
 */
820
function wpinv_get_cart_item_quantity() {
821
    return 1;
822
}
823
824
/**
825
 * @deprecated
826
 */
827
function wpinv_get_cart_item_price_name() {
828
    return '';
829
}
830
831
/**
832
 * @deprecated
833
 */
834
function wpinv_get_cart_item_name() {
835
    return '';
836
}
837
838
/**
839
 * @deprecated
840
 */
841
function wpinv_get_cart_item_price() {
842
    return 0;
843
}
844
845
/**
846
 * @deprecated
847
 */
848
function wpinv_get_cart_item_price_id() {
849
    return 0;
850
}
851
852
/**
853
 * @deprecated
854
 */
855
function wpinv_item_show_price( $item_id = 0, $echo = true ) {
856
857
    if ( $echo ) {
858
        echo wp_kses_post( wpinv_item_price( $item_id ) );
0 ignored issues
show
It seems like wpinv_item_price($item_id) can also be of type false; however, parameter $data of wp_kses_post() does only seem to accept string, maybe add an additional type check? ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-type  annotation

858
        echo wp_kses_post( /** @scrutinizer ignore-type */ wpinv_item_price( $item_id ) );
Loading history...
859
    } else {
860
        return wpinv_item_price( $item_id );
861
    }
862
863
}
864
865
/**
866
 * @deprecated
867
 */
868
function wpinv_cart_total_label() {}
869
870
/**
871
 * @deprecated
872
 */
873
function wpinv_html_dropdown() {}
874
875
/**
876
 * @deprecated
877
 */
878
function wpinv_has_active_discounts() {
879
    return true;
880
}
881
882
/**
883
 * @deprecated
884
 */
885
function wpinv_get_discounts() {}
886
887
/**
888
 * @deprecated
889
 */
890
function wpinv_get_all_discounts() {}
891
892
/**
893
 * @deprecated
894
 */
895
function wpinv_is_discount_valid() {
896
    return true;
897
}
898
899
/**
900
 * @deprecated
901
 */
902
function wpinv_is_discount_active() {
903
    return false;
904
}
905
906
/**
907
 * @deprecated
908
 */
909
function wpinv_update_discount_status() {}
910
911
/**
912
 * @deprecated
913
 */
914
function wpinv_discount_exists() {
915
    return false;
916
}
917
918
/**
919
 * @deprecated
920
 */
921
function wpinv_store_discount() {}
922
923
/**
924
 * @deprecated
925
 */
926
function wpinv_remove_discount() {}
927
928
/**
929
 * @deprecated
930
 */
931
function wpinv_get_discount_code() {}
932
933
/**
934
 * @deprecated
935
 */
936
function wpinv_get_discount_start_date() {}
937
938
/**
939
 * @deprecated
940
 */
941
function wpinv_get_discount_expiration() {}
942
943
/**
944
 * @deprecated
945
 */
946
function wpinv_get_discount_max_uses() {}
947
948
/**
949
 * @deprecated
950
 */
951
function wpinv_get_discount_min_total() {}
952
953
/**
954
 * @deprecated
955
 */
956
function wpinv_get_discount_max_total() {}
957
958
/**
959
 * @deprecated
960
 */
961
function wpinv_get_discount_amount() {}
962
963
/**
964
 * @deprecated
965
 */
966
function wpinv_discount_item_reqs_met() {}
967
968
/**
969
 * @deprecated
970
 */
971
function wpinv_is_discount_used() {}
972
973
/**
974
 * @deprecated
975
 */
976
function wpinv_get_discount_id_by_code() {}
977
978
/**
979
 * @deprecated
980
 */
981
function wpinv_get_discounted_amount() {}
982
983
/**
984
 * @deprecated
985
 */
986
function wpinv_increase_discount_usage() {}
987
988
/**
989
 * @deprecated
990
 */
991
function wpinv_decrease_discount_usage() {}
992
993
/**
994
 * @deprecated
995
 */
996
function wpinv_format_discount_rate() {}
997
998
/**
999
 * @deprecated
1000
 */
1001
function wpinv_unset_all_cart_discounts() {}
1002
1003
/**
1004
 * @deprecated
1005
 */
1006
function wpinv_get_cart_discounts() {}
1007
1008
/**
1009
 * @deprecated
1010
 */
1011
function wpinv_cart_has_discounts() {}
1012
1013
/**
1014
 * @deprecated
1015
 */
1016
function wpinv_get_cart_discounted_amount() {}
1017
1018
/**
1019
 * @deprecated
1020
 */
1021
function wpinv_get_discount_label() {}
1022
1023
/**
1024
 * @deprecated
1025
 */
1026
function wpinv_cart_discount_label() {}
1027
1028
/**
1029
 * @deprecated
1030
 */
1031
function wpinv_check_delete_discount() {}
1032
1033
/**
1034
 * @deprecated
1035
 */
1036
function wpinv_discount_amount() {}
1037
1038
/**
1039
 * @deprecated
1040
 */
1041
function wpinv_is_discount_expired() {}
1042
1043
/**
1044
 * @deprecated
1045
 */
1046
function wpinv_is_discount_started() {}
1047
1048
/**
1049
 * @deprecated
1050
 */
1051
function wpinv_check_discount_dates() {}
1052
1053
/**
1054
 * @deprecated
1055
 */
1056
function wpinv_is_discount_maxed_out() {}
1057
1058
/**
1059
 * @deprecated
1060
 */
1061
function wpinv_discount_is_min_met() {}
1062
1063
/**
1064
 * @deprecated
1065
 */
1066
function wpinv_discount_is_max_met() {}
1067
1068
/**
1069
 * @deprecated
1070
 */
1071
function wpinv_discount_is_single_use() {}
1072
1073
/**
1074
 * @deprecated
1075
 */
1076
function wpinv_get_discount_excluded_items() {}
1077
1078
/**
1079
 * @deprecated
1080
 */
1081
function wpinv_get_discount_item_reqs() {}
1082
1083
/**
1084
 * @deprecated
1085
 */
1086
function wpinv_get_discount_item_condition() {}
1087
1088
/**
1089
 * @deprecated
1090
 */
1091
function wpinv_is_discount_not_global() {}
1092
1093
/**
1094
 * @deprecated
1095
 */
1096
function wpinv_get_discount_type() {}
1097
1098
/**
1099
 * @deprecated
1100
 */
1101
function wpinv_get_discount_uses() {}
1102
1103
/**
1104
 * @deprecated
1105
 */
1106
function wpinv_get_discount_by_code() {}
1107
1108
/**
1109
 * @deprecated
1110
 */
1111
function wpinv_discount_bulk_actions() {}
1112
1113
/**
1114
 * @deprecated
1115
 */
1116
function wpinv_check_quick_edit() {}
1117
1118
/**
1119
 * @deprecated
1120
 */
1121
function wpinv_item_disable_quick_edit() {}
1122
1123
/**
1124
 * @deprecated
1125
 */
1126
function wpinv_table_primary_column() {}
1127
1128
/**
1129
 * @deprecated
1130
 */
1131
function wpinv_disable_months_dropdown() {}
1132
1133
/**
1134
 * @deprecated
1135
 */
1136
function wpinv_item_type_class() {}
1137
1138
/**
1139
 * @deprecated
1140
 */
1141
function wpinv_vat_ip_lookup_callback() {}
1142
1143
/**
1144
 * @deprecated.
1145
 */
1146
function wpinv_ip_geolocation() {}
1147
1148
/**
1149
 * @deprecated
1150
 */
1151
function getpaid_ip_location_url() {}
1152
1153
/**
1154
 * @deprecated
1155
 */
1156
function getpaid_geolocate_ip_address() {}
1157
1158
/**
1159
 * @deprecated
1160
 */
1161
function wpinv_validate_url_token() {
1162
    return false;
1163
}
1164
1165
/**
1166
 * @deprecated
1167
 */
1168
function wpinv_get_item_token() {}
1169
1170
/**
1171
 * @deprecated
1172
 */
1173
function wpinv_item_in_cart() {
1174
    return false;
1175
}
1176
1177
/**
1178
 * @deprecated
1179
 */
1180
function wpinv_html_date_field() {}
1181
1182
/**
1183
 * @deprecated
1184
 */
1185
function wpinv_get_formatted_tax_rate() {}
1186
1187
/**
1188
 * @deprecated
1189
 */
1190
function wpinv_get_cart_item_tax() {}
1191
1192
/**
1193
 * @deprecated
1194
 */
1195
function wpinv_cart_item_price() {}
1196
1197
/**
1198
 * @deprecated
1199
 */
1200
function wpinv_cart_item_subtotal() {}
1201
1202
/**
1203
 * @deprecated
1204
 */
1205
function wpinv_cart_item_tax() {}
1206
1207
/**
1208
 * @deprecated
1209
 */
1210
function wpinv_calculate_tax() {}
1211
1212
/**
1213
 * @deprecated
1214
 */
1215
function wpinv_get_tax_rate() {}
1216
1217
/**
1218
 * @deprecated
1219
 */
1220
function wpinv_eu_fallback_rate_callback() {}
1221
1222
/**
1223
 * @deprecated
1224
 */
1225
function wpinv_vat_number_callback() {}
1226
1227
/**
1228
 * @deprecated
1229
 */
1230
function wpinv_vat_rate_add_callback() {}
1231
1232
/**
1233
 * @deprecated
1234
 */
1235
function wpinv_vat_rate_delete_callback() {}
1236
1237
/**
1238
 * @deprecated
1239
 */
1240
function wpinv_vat_rates_callbacks() {}
1241
1242
/**
1243
 * @deprecated
1244
 */
1245
function wpinv_invalid_invoice_content() {}
1246
1247
/**
1248
 * @deprecated
1249
 */
1250
function wpinv_receipt_billing_address() {}
1251
1252
/**
1253
 * @deprecated
1254
 */
1255
function wpinv_guest_redirect() {}
1256
1257
/**
1258
 * @deprecated
1259
 */
1260
function wpinv_login_user() {}
1261
1262
/**
1263
 * @deprecated
1264
 */
1265
function wpinv_get_users_invoices() {
1266
    return array();
1267
}
1268
1269
/**
1270
 * Fetchs an invoice subscription from the database.
1271
 *
1272
 * @return WPInv_Subscription|bool
1273
 * @deprecated
1274
 */
1275
function wpinv_get_subscription( $invoice ) {
1276
	return wpinv_get_invoice_subscription( $invoice );
1277
}
1278