mirror of
				https://github.com/invoiceninja/invoiceninja.git
				synced 2025-11-03 22:17:35 -05:00 
			
		
		
		
	Process markdown if process_markdown is available
				
					
				
			This commit is contained in:
		
							parent
							
								
									ac820c09ce
								
							
						
					
					
						commit
						ce78c1bc94
					
				@ -92,10 +92,12 @@ trait PdfMakerUtilities
 | 
				
			|||||||
            $contains_html = false;
 | 
					            $contains_html = false;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
            if ($child['element'] !== 'script') {
 | 
					            if ($child['element'] !== 'script') {
 | 
				
			||||||
 | 
					                if (array_key_exists('process_markdown', $this->data) && $this->data['process_markdown']) {
 | 
				
			||||||
                    $child['content'] = $this->commonmark->convertToHtml($child['content'] ?? '');
 | 
					                    $child['content'] = $this->commonmark->convertToHtml($child['content'] ?? '');
 | 
				
			||||||
 | 
					                } else {
 | 
				
			||||||
 | 
					                    $child['content'] = array_key_exists('content', $child) ? nl2br($child['content']) : '';
 | 
				
			||||||
 | 
					                }
 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
 | 
					 | 
				
			||||||
            // $child['content'] = array_key_exists('content', $child) ? nl2br($child['content']) : '';
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
            if (isset($child['content'])) {
 | 
					            if (isset($child['content'])) {
 | 
				
			||||||
                if (isset($child['is_empty']) && $child['is_empty'] === true) {
 | 
					                if (isset($child['is_empty']) && $child['is_empty'] === true) {
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user