Skip to content

Commit

Permalink
Merge pull request #24 from tarfin-labs/k_path_images_constant_bugfix
Browse files Browse the repository at this point in the history
Check if  constant is already defined before.
  • Loading branch information
tkaratug authored Oct 10, 2024
2 parents 75c8a4a + 7883c42 commit cf2ada4
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
5 changes: 4 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,10 @@ All notable changes to `easy-pdf` will be documented in this file.

## [Unreleased]

## 3.0.0 - 2024-04-08
## 2.10.1 - 2024-10-10
- Fix re-defining `K_PATH_IMAGES` constant bug.

## 2.10.0 - 2024-04-08
- Laravel 11 and PHP 8.3 support added.

## 2.9.0 - 2023-08-16
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
[![Total Downloads](https://img.shields.io/packagist/dt/tarfin-labs/easy-pdf.svg?style=flat-square)](https://packagist.org/packages/tarfin-labs/easy-pdf)

## Introduction
easy-pdf is a [tcpdf](https://tcpdf.org/) wrapper for Laravel 6.x, 7.x, 8.x, 9.x, 10.x.
easy-pdf is a [tcpdf](https://tcpdf.org/) wrapper for Laravel 6.x, 7.x, 8.x, 9.x, 10.x, 11.x.

## Installation

Expand Down
2 changes: 1 addition & 1 deletion src/EasyPdf.php
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ class EasyPdf
*/
public function __construct(?string $imagePath = null)
{
if ($imagePath !== null) {
if ($imagePath !== null && ! defined('K_PATH_IMAGES')) {
define('K_PATH_IMAGES', $imagePath);
}

Expand Down

0 comments on commit cf2ada4

Please sign in to comment.