Source:
<code>public void createBeans(Environment environment) { beanDeployer.addBuiltInBean(new InjectionPointBean(beanManager)); beanDeployer.addBuiltInBean(new EventMetadataBean(beanManager)); beanDeployer.addBuiltInBean(new EventBean(beanManager)); beanDeployer.addBuiltInBean(new InstanceBean(beanManager)); beanDeployer.addBuiltInBean(new ConversationBean(beanManager)); beanDeployer.addBuiltInBean(new BeanMetadataBean(beanManager)); beanDeployer.addBuiltInBean(new InterceptedBeanMetadataBean(beanManager)); beanDeployer.addBuiltInBean(new DecoratedBeanMetadataBean(beanManager)); beanDeployer.addBuiltInBean(new InterceptorMetadataBean(beanManager)); beanDeployer.addBuiltInBean(new DecoratorMetadataBean(beanManager)); if (Reflections.isClassLoadable(ServletApiAbstraction.SERVLET_CONTEXT_CLASS_NAME, WeldClassLoaderResourceLoader.INSTANCE)) { beanDeployer.addBuiltInBean(new HttpServletRequestBean(beanManager)); beanDeployer.addBuiltInBean(new HttpSessionBean(beanManager)); beanDeployer.addBuiltInBean(new ServletContextBean(beanManager)); } if (beanManager.getServices().contains(TransactionServices.class)) { beanDeployer.addBuiltInBean(new UserTransactionBean(beanManager)); } if (beanManager.getServices().contains(SecurityServices.class)) { beanDeployer.addBuiltInBean(new PrincipalBean(beanManager)); } for (ContextHolder<? extends Context> context : contexts) { beanDeployer.addBuiltInBean(ContextBean.of(context, beanManager)); } if (beanDeploymentArchive.getBeansXml() instanceof TrimmableBeansXml) { <START> if (((TrimmableBeansXml) beanDeploymentArchive.getBeansXml()).isTrimmed()) { <END> beanDeployer.getEnvironment().trim(); } } beanDeployer.createClassBeans(); }</code><technical_language>This is readable... I like: TrimmableBeansXml trimmableBeansXml = ... if (trimmableBeansXml.isTrimmed()) { ... } minor.... PR good</technical_language>

Target:
public void createBeans(Environment environment) { beanDeployer.addBuiltInBean(new InjectionPointBean(beanManager)); beanDeployer.addBuiltInBean(new EventMetadataBean(beanManager)); beanDeployer.addBuiltInBean(new EventBean(beanManager)); beanDeployer.addBuiltInBean(new InstanceBean(beanManager)); beanDeployer.addBuiltInBean(new ConversationBean(beanManager)); beanDeployer.addBuiltInBean(new BeanMetadataBean(beanManager)); beanDeployer.addBuiltInBean(new InterceptedBeanMetadataBean(beanManager)); beanDeployer.addBuiltInBean(new DecoratedBeanMetadataBean(beanManager)); beanDeployer.addBuiltInBean(new InterceptorMetadataBean(beanManager)); beanDeployer.addBuiltInBean(new DecoratorMetadataBean(beanManager)); if (Reflections.isClassLoadable(ServletApiAbstraction.SERVLET_CONTEXT_CLASS_NAME, WeldClassLoaderResourceLoader.INSTANCE)) { beanDeployer.addBuiltInBean(new HttpServletRequestBean(beanManager)); beanDeployer.addBuiltInBean(new HttpSessionBean(beanManager)); beanDeployer.addBuiltInBean(new ServletContextBean(beanManager)); } if (beanManager.getServices().contains(TransactionServices.class)) { beanDeployer.addBuiltInBean(new UserTransactionBean(beanManager)); } if (beanManager.getServices().contains(SecurityServices.class)) { beanDeployer.addBuiltInBean(new PrincipalBean(beanManager)); } for (ContextHolder<? extends Context> context : contexts) { beanDeployer.addBuiltInBean(ContextBean.of(context, beanManager)); } if (beanDeploymentArchive.getBeansXml() instanceof TrimmableBeansXml) { TrimmableBeansXml beansXml = (TrimmableBeansXml) beanDeploymentArchive.getBeansXml(); if (beansXml.isTrimmed()) { beanDeployer.getEnvironment().trim(); } } beanDeployer.createClassBeans(); }