everlutionsk /
ajaxcom-bundle
| 1 | <?php |
||
| 2 | |||
| 3 | declare(strict_types=1); |
||
| 4 | |||
| 5 | namespace Everlution\AjaxcomBundle\DependencyInjection; |
||
| 6 | |||
| 7 | use Symfony\Component\Config\Definition\Builder\TreeBuilder; |
||
| 8 | use Symfony\Component\Config\Definition\ConfigurationInterface; |
||
| 9 | |||
| 10 | /** |
||
| 11 | * Class Configuration. |
||
| 12 | * |
||
| 13 | * @author Ivan Barlog <[email protected]> |
||
| 14 | */ |
||
| 15 | class Configuration implements ConfigurationInterface |
||
| 16 | { |
||
| 17 | const FLASH_TEMPLATE = 'flash_template'; |
||
| 18 | const FLASH_BLOCK_ID = 'flash_block_id'; |
||
| 19 | const PERSISTENT_CLASS = 'persistent_class'; |
||
| 20 | const BLOCKS_TO_RENDER = 'blocks_to_render'; |
||
| 21 | const ID = 'id'; |
||
| 22 | const REFRESH = 'refresh'; |
||
| 23 | |||
| 24 | public function getConfigTreeBuilder() |
||
| 25 | { |
||
| 26 | $treeBuilder = new TreeBuilder('everlution_ajaxcom'); |
||
| 27 | |||
| 28 | if (method_exists($treeBuilder, 'getRootNode')) { |
||
| 29 | $rootNode = $treeBuilder->getRootNode(); |
||
| 30 | } else { |
||
| 31 | // for symfony/config 4.1 and older |
||
| 32 | $rootNode = $treeBuilder->root('everlution_ajaxcom'); |
||
|
0 ignored issues
–
show
|
|||
| 33 | } |
||
| 34 | |||
| 35 | $rootNode |
||
| 36 | ->children() |
||
| 37 | ->scalarNode(self::FLASH_TEMPLATE)->defaultValue('@EverlutionAjaxcom/flash_message.html.twig')->end() |
||
| 38 | ->scalarNode(self::FLASH_BLOCK_ID)->defaultValue('flash_message')->end() |
||
| 39 | ->scalarNode(self::PERSISTENT_CLASS)->defaultValue('ajaxcom-persistent')->end() |
||
| 40 | ->arrayNode(self::BLOCKS_TO_RENDER) |
||
| 41 | ->arrayPrototype() |
||
| 42 | ->children() |
||
| 43 | ->scalarNode(self::ID)->end() |
||
| 44 | ->scalarNode(self::REFRESH)->defaultFalse()->end() |
||
| 45 | ->end() |
||
| 46 | ->end() |
||
| 47 | ->end() |
||
| 48 | ->end(); |
||
| 49 | |||
| 50 | return $treeBuilder; |
||
| 51 | } |
||
| 52 | } |
||
| 53 |
This check looks for calls to methods that do not seem to exist on a given type. It looks for the method on the type itself as well as in inherited classes or implemented interfaces.
This is most likely a typographical error or the method has been renamed.