summaryrefslogtreecommitdiff
path: root/FS
diff options
context:
space:
mode:
Diffstat (limited to 'FS')
-rw-r--r--FS/FS/Template_Mixin.pm17
1 files changed, 13 insertions, 4 deletions
diff --git a/FS/FS/Template_Mixin.pm b/FS/FS/Template_Mixin.pm
index 563cbdd8f..44d44e185 100644
--- a/FS/FS/Template_Mixin.pm
+++ b/FS/FS/Template_Mixin.pm
@@ -2094,11 +2094,20 @@ sub generate_email {
if (!@text) {
- warn "$me generating plain text invoice"
- if $DEBUG;
+ if ( $conf->config($tc.'template') ) {
+
+ warn "$me generating plain text invoice"
+ if $DEBUG;
- # 'print_text' argument is no longer used
- @text = $self->print_text(\%args);
+ # 'print_text' argument is no longer used
+ @text = $self->print_text(\%args);
+
+ } else {
+
+ warn "$me no plain text version exists; sending empty message body"
+ if $DEBUG;
+
+ }
}