-
Notifications
You must be signed in to change notification settings - Fork 1
/
openmage.diff
50 lines (49 loc) · 2.04 KB
/
openmage.diff
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
# for zf1-future 1.23.5 / OpenMage 20.3.0
# this is for maillog
diff --git a/vendor/shardj/zf1-future/library/Zend/Mail/Transport/Sendmail.php b/vendor/shardj/zf1-future/library/Zend/Mail/Transport/Sendmail.php
index 83b6a98bd..78196fb12 100644
--- a/vendor/shardj/zf1-future/library/Zend/Mail/Transport/Sendmail.php
+++ b/vendor/shardj/zf1-future/library/Zend/Mail/Transport/Sendmail.php
@@ -97,6 +97,10 @@
*/
public function _sendMail()
{
+ // @see https://github.com/luigifab/openmage-maillog
+ if (Mage::helper('core')->isModuleEnabled('Luigifab_Maillog') && Mage::getStoreConfigFlag('maillog/general/enabled'))
+ return Mage::helper('maillog')->sendMail($this, $this->_mail, $this->_parts);
+
$recipients = $this->recipients;
$subject = $this->_mail->getSubject();
$body = $this->body;
diff --git a/lib/Varien/Filter/Template.php b/lib/Varien/Filter/Template.php
index 83b6a98bd..78196fb12 100644
--- a/lib/Varien/Filter/Template.php
+++ b/lib/Varien/Filter/Template.php
@@ -20,7 +20,9 @@
* @package Varien_Filter
*/
-class Varien_Filter_Template implements Zend_Filter_Interface
+// @see https://github.com/luigifab/openmage-maillog
+//class Varien_Filter_Template implements Zend_Filter_Interface
+class Varien_Filter_Template extends Luigifab_Maillog_Model_Filter implements Zend_Filter_Interface
{
/**
* Cunstruction regular expression
@@ -128,7 +130,7 @@
* @param string $value
* @return string
*/
- public function filter($value)
+ public function filter2($value)
{
// "depend" and "if" operands should be first
$directives = [
@@ -281,7 +283,7 @@
* @param string|null $default default value
* @return string
*/
- protected function _getVariable($value, $default = '{no_value_defined}')
+ protected function _getVariable2($value, $default = '{no_value_defined}')
{
Varien_Profiler::start("email_template_proccessing_variables");
$tokenizer = new Varien_Filter_Template_Tokenizer_Variable();