Skip to content

Commit

Permalink
Merge pull request #1495 from GravityPDF/pdf-trailingslash
Browse files Browse the repository at this point in the history
Support permalinks with trailing slash removed
  • Loading branch information
jakejackson1 authored Feb 19, 2024
2 parents 807bc8e + 5b4381b commit f8857e2
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/Model/Model_PDF.php
Original file line number Diff line number Diff line change
Expand Up @@ -858,6 +858,8 @@ public function get_pdf_url( $pid, $id, $download = false, $print = false, $esc
$url .= 'download/';
}

$url = user_trailingslashit( $url );

if ( $print ) {
$url .= '?print=1';
}
Expand Down

0 comments on commit f8857e2

Please sign in to comment.