File tree Expand file tree Collapse file tree 2 files changed +15
-3
lines changed
Expand file tree Collapse file tree 2 files changed +15
-3
lines changed Original file line number Diff line number Diff line change @@ -100,7 +100,11 @@ function update($event_name, $data) {
100100
101101 if ($ data ["new " ]["active " ] == 'y ' ) {
102102 // Open master template
103- $ tpl = file_get_contents ($ conf ["rootpath " ].'/conf/getmail.conf.master ' );
103+ if (file_exists ($ conf ["rootpath " ].'/conf-custom/getmail.conf.master ' )) {
104+ $ tpl = file_get_contents ($ conf ["rootpath " ].'/conf-custom/getmail.conf.master ' );
105+ } else {
106+ $ tpl = file_get_contents ($ conf ["rootpath " ].'/conf/getmail.conf.master ' );
107+ }
104108
105109 // Shall emails be deleted after retrieval
106110 if ($ data ["new " ]["source_delete " ] == 'y ' ) {
Original file line number Diff line number Diff line change @@ -137,7 +137,11 @@ function update($event_name, $data) {
137137 }
138138
139139 // Load the master template
140- $ tpl = file_get_contents ($ conf ["rootpath " ].'/conf/autoresponder.master ' );
140+ if (file_exists ($ conf ["rootpath " ].'/conf-custom/autoresponder.master ' )) {
141+ $ tpl = file_get_contents ($ conf ["rootpath " ].'/conf-custom/autoresponder.master ' );
142+ } else {
143+ $ tpl = file_get_contents ($ conf ["rootpath " ].'/conf/autoresponder.master ' );
144+ }
141145 $ tpl = str_replace ('{vmail_mailbox_base} ' , $ mail_config ["homedir_path " ], $ tpl );
142146
143147 if ($ data ["new " ]["autoresponder_start_date " ] != '0000-00-00 00:00:00 ' ) { // Dates have been set
@@ -201,7 +205,11 @@ function update($event_name, $data) {
201205 }
202206
203207 if ($ data ["new " ]["move_junk " ] == 'y ' ) {
204- $ mailfilter_content .= file_get_contents ($ conf ["rootpath " ].'/conf/mailfilter_move_junk.master ' )."\n" ;
208+ if (file_exists ($ conf ["rootpath " ].'/conf-custom/mailfilter_move_junk.master ' )) {
209+ $ mailfilter_content .= file_get_contents ($ conf ["rootpath " ].'/conf-custom/mailfilter_move_junk.master ' )."\n" ;
210+ } else {
211+ $ mailfilter_content .= file_get_contents ($ conf ["rootpath " ].'/conf/mailfilter_move_junk.master ' )."\n" ;
212+ }
205213 }
206214 $ mailfilter_content .= $ data ["new " ]["custom_mailfilter " ];
207215
You can’t perform that action at this time.
0 commit comments