Skip to content

Commit

Permalink
Fix: Call to undefined function standardSerializer() on UBL (#1032)
Browse files Browse the repository at this point in the history
  • Loading branch information
alexmigf authored Jan 24, 2025
1 parent 80be5e6 commit 17b0a8a
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions ubl/Builders/SabreBuilder.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,10 @@ public function build( Document $document ): string {

// Map namespaces (Sabre requires URI => prefix)
$this->service->namespaceMap = array_flip( $document->get_namespaces() );

if ( ! function_exists( 'WPO\\IPS\\Vendor\\Sabre\\Xml\\Serializer\\standardSerializer' ) ) {
require_once WPO_WCPDF()->plugin_path() . '/vendor/sabre/xml/lib/Serializer/functions.php';
}

return $this->service->write(
$document->get_root_element(),
Expand Down

0 comments on commit 17b0a8a

Please # to comment.