cosmetic fix
This commit is contained in:
parent
1741e80aed
commit
5f200bfa69
5 changed files with 16 additions and 9 deletions
|
@ -1,3 +1,10 @@
|
||||||
|
emailNotification 1.8 - 2023.12.24
|
||||||
|
===========================================================
|
||||||
|
* Require Dotclear 2.28
|
||||||
|
* Require PHP 8.1
|
||||||
|
* Fix translation
|
||||||
|
* Fix type hint
|
||||||
|
|
||||||
emailNotification 1.7 - 2023.10.16
|
emailNotification 1.7 - 2023.10.16
|
||||||
===========================================================
|
===========================================================
|
||||||
* Require Dotclear 2.28
|
* Require Dotclear 2.28
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
# README
|
# README
|
||||||
|
|
||||||
[![Release](https://img.shields.io/badge/release-1.7-a2cbe9.svg)](https://git.dotclear.watch/JcDenis/emailNotification/releases)
|
[![Release](https://img.shields.io/badge/release-1.8-a2cbe9.svg)](https://git.dotclear.watch/JcDenis/emailNotification/releases)
|
||||||
![Date](https://img.shields.io/badge/date-2023.10.16-c44d58.svg)
|
![Date](https://img.shields.io/badge/date-2023.12.24-c44d58.svg)
|
||||||
[![Dotclear](https://img.shields.io/badge/dotclear-v2.28-137bbb.svg)](https://fr.dotclear.org/download)
|
[![Dotclear](https://img.shields.io/badge/dotclear-v2.28-137bbb.svg)](https://fr.dotclear.org/download)
|
||||||
[![Dotaddict](https://img.shields.io/badge/dotaddict-official-9ac123.svg)](https://plugins.dotaddict.org/dc2/details/emailNotification)
|
[![Dotaddict](https://img.shields.io/badge/dotaddict-official-9ac123.svg)](https://plugins.dotaddict.org/dc2/details/emailNotification)
|
||||||
[![License](https://img.shields.io/badge/license-GPL--2.0-ececec.svg)](https://git.dotclear.watch/JcDenis/emailNotification/src/branch/master/LICENSE)
|
[![License](https://img.shields.io/badge/license-GPL--2.0-ececec.svg)](https://git.dotclear.watch/JcDenis/emailNotification/src/branch/master/LICENSE)
|
||||||
|
|
|
@ -18,7 +18,7 @@ $this->registerModule(
|
||||||
'Email notification',
|
'Email notification',
|
||||||
'Email notification',
|
'Email notification',
|
||||||
'Olivier Meunier and contributors',
|
'Olivier Meunier and contributors',
|
||||||
'1.7',
|
'1.8',
|
||||||
[
|
[
|
||||||
'requires' => [['core', '2.28']],
|
'requires' => [['core', '2.28']],
|
||||||
'permissions' => 'My',
|
'permissions' => 'My',
|
||||||
|
|
|
@ -2,10 +2,10 @@
|
||||||
<modules xmlns:da="http://dotaddict.org/da/">
|
<modules xmlns:da="http://dotaddict.org/da/">
|
||||||
<module id="emailNotification">
|
<module id="emailNotification">
|
||||||
<name>Email notification</name>
|
<name>Email notification</name>
|
||||||
<version>1.7</version>
|
<version>1.8</version>
|
||||||
<author>Olivier Meunier and contributors</author>
|
<author>Olivier Meunier and contributors</author>
|
||||||
<desc>Email notification</desc>
|
<desc>Email notification</desc>
|
||||||
<file>https://git.dotclear.watch/JcDenis/emailNotification/releases/download/v1.7/plugin-emailNotification.zip</file>
|
<file>https://git.dotclear.watch/JcDenis/emailNotification/releases/download/v1.8/plugin-emailNotification.zip</file>
|
||||||
<da:dcmin>2.28</da:dcmin>
|
<da:dcmin>2.28</da:dcmin>
|
||||||
<da:details>https://git.dotclear.watch/JcDenis/emailNotification/src/branch/master/README.md</da:details>
|
<da:details>https://git.dotclear.watch/JcDenis/emailNotification/src/branch/master/README.md</da:details>
|
||||||
<da:support>https://git.dotclear.watch/JcDenis/emailNotification/issues</da:support>
|
<da:support>https://git.dotclear.watch/JcDenis/emailNotification/issues</da:support>
|
||||||
|
|
|
@ -117,16 +117,16 @@ class Frontend extends Process
|
||||||
$subject = '[' . App::blog()->name() . '] ' . sprintf(__('"%s" - New comment'), $rs->f('post_title'));
|
$subject = '[' . App::blog()->name() . '] ' . sprintf(__('"%s" - New comment'), $rs->f('post_title'));
|
||||||
$subject = Mail::B64Header($subject);
|
$subject = Mail::B64Header($subject);
|
||||||
|
|
||||||
$msg = preg_replace('%</p>\s*<p>%msu', "\n\n", $rs->f('comment_content'));
|
$msg = preg_replace('%</p>\s*<p>%msu', "\n\n", (string) $rs->f('comment_content'));
|
||||||
$msg = Html::clean($msg);
|
$msg = Html::clean($msg);
|
||||||
$msg = html_entity_decode($msg);
|
$msg = html_entity_decode($msg);
|
||||||
|
|
||||||
if ((int) $cur->getField('comment_status') == App::blog()::COMMENT_PUBLISHED) {
|
if ((int) $cur->getField('comment_status') == App::blog()::COMMENT_PUBLISHED) {
|
||||||
$status = __('published');
|
$status = __('Published');
|
||||||
} elseif ((int) $cur->getField('comment_status') == App::blog()::COMMENT_UNPUBLISHED) {
|
} elseif ((int) $cur->getField('comment_status') == App::blog()::COMMENT_UNPUBLISHED) {
|
||||||
$status = __('unpublished');
|
$status = __('Unpublished');
|
||||||
} elseif ((int) $cur->getField('comment_status') == App::blog()::COMMENT_PENDING) {
|
} elseif ((int) $cur->getField('comment_status') == App::blog()::COMMENT_PENDING) {
|
||||||
$status = __('pending');
|
$status = __('Pending');
|
||||||
} else {
|
} else {
|
||||||
// unknown status
|
// unknown status
|
||||||
$status = $cur->getField('comment_status');
|
$status = $cur->getField('comment_status');
|
||||||
|
|
Loading…
Reference in a new issue