Skip to content

Commit

Permalink
1.3.19 - First page thumbnail bug fix
Browse files Browse the repository at this point in the history
  • Loading branch information
antongorodezkiy committed Sep 11, 2017
1 parent 28099d2 commit 865f9ee
Show file tree
Hide file tree
Showing 5 changed files with 22 additions and 7 deletions.
7 changes: 5 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

**Tested up to:** 4.7

**Stable tag:** 1.3.18
**Stable tag:** 1.3.19

**License:** GPLv2

Expand Down Expand Up @@ -80,7 +80,10 @@ Plugin allows you to embed normal, big and very big pdf documents to the wordpre

## Changelog ##

# 1.3.18 - 2017-07-27
## 1.3.19 - 2017-09-11
* First page thumbnail bug fix

## 1.3.18 - 2017-07-27
* PDF support improvement

## 1.3.17 - 2017-03-29
Expand Down
6 changes: 5 additions & 1 deletion controllers/PdfController.php
Original file line number Diff line number Diff line change
Expand Up @@ -682,7 +682,7 @@ public static function getFirstPageGeometry(

@shell_exec($commnad);

$first_page_path = $pdf_upload_dir.'/page-'.$page_number.'.jpg';
$first_page_path = $first_page_image_path = $pdf_upload_dir.'/page-'.$page_number.'.jpg';
}
else {
$first_page_path = $pdf_file_path;
Expand All @@ -703,6 +703,10 @@ public static function getFirstPageGeometry(
$Imagick->destroy();
}

if (file_exists($first_page_image_path) && is_file($first_page_image_path)) {
unlink($first_page_image_path);
}

return $geometry;
}

Expand Down
9 changes: 7 additions & 2 deletions documentation/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">

<title>WordPress PDF Light Viewer Plugin & Pro Addon Documentation for version 1.3.18 & pro 0.1.4</title>
<title>WordPress PDF Light Viewer Plugin & Pro Addon Documentation for version 1.3.19 & pro 0.1.4</title>

<link rel="stylesheet" href="css/pure.css" />
<link rel="stylesheet" href="css/prism.css" />
Expand Down Expand Up @@ -88,7 +88,7 @@
<div id="main" class="doc-section">
<div class="header">
<div class="logo-header"></div>
<h1>WordPress PDF Light Viewer Plugin v1.3.16<br />& <span class="pure-button pure-button-primary">PRO</span> Addon v0.1.4<br/>Documentation</h1>
<h1>WordPress PDF Light Viewer Plugin v1.3.19<br />& <span class="pure-button pure-button-primary">PRO</span> Addon v0.1.4<br/>Documentation</h1>
<h2>What did you get?</h2>
</div>

Expand Down Expand Up @@ -772,6 +772,11 @@ <h1>Changelog</h1>

<h3>PDF Light Viewer</h3>

<h4 class="content-subhead">1.3.19 - 2017-09-11</h4>
<ul>
<li>First page thumbnail bug fix</li>
</ul>

<h4 class="content-subhead">1.3.18 - 2017-07-27</h4>
<ul>
<li>PDF support improvement</li>
Expand Down
2 changes: 1 addition & 1 deletion pdf-light-viewer.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Plugin Name: PDF Light Viewer Plugin
Plugin URI: http://pdf-light-viewer.wp.teamlead.pw/
Description: Wordpress plugin to embed normal, large and very large pdf documents to the wordpress site as flipbooks with thumbnail navigation.
Version: 1.3.18
Version: 1.3.19
Author: Teamlead Power
Author URI: http://teamlead.pw/
License: GPLv2
Expand Down
5 changes: 4 additions & 1 deletion readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Tags: pdf, pdfs, embed, pdf embed, publish pdf, import pdf, flipbook
Donate link:
Requires at least: 3.5
Tested up to: 4.7
Stable tag: 1.3.18
Stable tag: 1.3.19
License: GPLv2
License URI: http://www.gnu.org/licenses/gpl-2.0.html

Expand Down Expand Up @@ -65,6 +65,9 @@ Plugin allows you to embed normal, big and very big pdf documents to the wordpre

== Changelog ==

== 1.3.19 - 2017-09-11 ==
* First page thumbnail bug fix

== 1.3.18 - 2017-07-27 ==
* PDF support improvement

Expand Down

0 comments on commit 865f9ee

Please sign in to comment.