Align MustacheViewResolver with other similar resolvers
The `FreeMarkerViewResolver` (and other template-based resolvers) in Spring Framework avoid using reflection if they know how to instantiate the view class. This change aligns with them. See gh-24011
This commit is contained in:
		
							parent
							
								
									699f03d5a6
								
							
						
					
					
						commit
						22693c17f3
					
				| 
						 | 
				
			
			@ -75,4 +75,9 @@ public class MustacheViewResolver extends AbstractTemplateViewResolver {
 | 
			
		|||
		return view;
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	@Override
 | 
			
		||||
	protected AbstractUrlBasedView instantiateView() {
 | 
			
		||||
		return (getViewClass() == MustacheView.class ? new MustacheView() : super.instantiateView());
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
}
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue