This repository was archived by the owner on Apr 29, 2019. It is now read-only.
  
  
  
  
    
    
    
      
    
  
  
    
File tree Expand file tree Collapse file tree 3 files changed +9
-1
lines changed 
lib/internal/Magento/Framework/View Expand file tree Collapse file tree 3 files changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -117,6 +117,7 @@ class Config
117117        'description '  => null ,
118118        'keywords '  => null ,
119119        'robots '  => null ,
120+         'title '  => null ,
120121    ];
121122
122123    /** 
Original file line number Diff line number Diff line change @@ -136,6 +136,12 @@ public function renderMetadata()
136136    protected  function  processMetadataContent ($ name , $ content )
137137    {
138138        $ method  = 'get '  . $ this  ->string ->upperCaseWords ($ name , '_ ' , '' );
139+         if  ($ name  === 'title ' ) {
140+             if  (!$ content ) {
141+                 $ content  = $ this  ->escaper ->escapeHtml ($ this  ->pageConfig ->$ method ()->get ());
142+             }
143+             return  $ content ;
144+         }
139145        if  (method_exists ($ this  ->pageConfig , $ method )) {
140146            $ content  = $ this  ->pageConfig ->$ method ();
141147        }
Original file line number Diff line number Diff line change 1313use  Magento \Framework \View \Page \Config ;
1414
1515/** 
16-  * @covers Magento\Framework\View\Page\Config 
16+  * @covers \ Magento\Framework\View\Page\Config 
1717 * 
1818 * @SuppressWarnings(PHPMD.CouplingBetweenObjects) 
1919 */ 
@@ -139,6 +139,7 @@ public function testMetadata()
139139            'description '  => null ,
140140            'keywords '  => null ,
141141            'robots '  => null ,
142+             'title '  => null ,
142143            'name '  => 'test_value ' ,
143144            'html_encoded '  => '<title><span class="test">Test</span></title> ' ,
144145        ];
    
 
   
 
     
   
   
          
     
  
    
     
 
    
      
     
 
     
    You can’t perform that action at this time.
  
 
    
  
     
    
      
        
     
 
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments