• Resolved olessol

    (@olessol)


    There is a warning in the woocommerce logs that some features are no longer supported and will be removed in future versions.

    Problem

    Wcpdf_get_packing_slip is used → from version 4.6.3 it should be replaced with: wcpdf_get_document( ‘packing-slip’, $order, $init );

    Wcpdf_get_invoice is used → replace with: wcpdf_get_document( ‘invoice’, $order, $init );

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Contributor alexmigf

    (@alexmigf)

    Hi @olessol

    Do you perhaps have one of our paid extensions, or a third-party plugin that integrates with our plugin?

    Thread Starter olessol

    (@olessol)

    I found this obsolete code in a file: wp-content/plugins/woocommerce-pdf-invoices-packing-slips/wpo-ips-functions.php

    Here is a part of the code. Lines 116-124

    function wcpdf_get_invoice( $order, $init = false ) {
    wcpdf_deprecated_function( __FUNCTION__, ‘4.6.3’, ‘wcpdf_get_document( \’invoice\’, $order, $init )’ );
    return wcpdf_get_document( ‘invoice’, $order, $init );
    }

    function wcpdf_get_packing_slip( $order, $init = false ) {
        wcpdf_deprecated_function( __FUNCTION__, ‘4.6.3’, ‘wcpdf_get_document( \’packing-slip\’, $order, $init )’ );
        return wcpdf_get_document( ‘packing-slip’, $order, $init );
    }

    No such code was found in other files.

    I saw this warning in the Woocommerce logs:

    Viewing log file wpo-wcpdf-2025-08-26
    2025-08-26T10:38:12+00:00Warning The wcpdf_get_packing_slip function is deprecated since version 4.6.3. Replace with wcpdf_get_document( ‘packing-slip’, $order, $init ).
    2025-08-26T10:38:12+00:00Warning The wcpdf_get_invoice function is deprecated since version 4.6.3. Replace with wcpdf_get_document( ‘invoice’, $order, $init ).
    2025-08-26T10:38:18+00:00Warning The wcpdf_get_packing_slip function is deprecated since version 4.6.3. Replace with wcpdf_get_document( ‘packing-slip’, $order, $init ).
    2025-08-26T10:38:18+00:00Warning The wcpdf_get_invoice function is deprecated since version 4.6.3. Replace with wcpdf_get_document( ‘invoice’, $order, $init ).


    Plugin Contributor alexmigf

    (@alexmigf)

    That code is correct. The notice is simply informing you that you should use wcpdf_get_document() going forward. Most likely, another plugin or a custom code snippet is still using the old functions. If you’re unsure which one is causing it, please contact us.

    Thread Starter olessol

    (@olessol)

    Thank you.

Viewing 4 replies - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.