File tree Expand file tree Collapse file tree 2 files changed +3
-19
lines changed Expand file tree Collapse file tree 2 files changed +3
-19
lines changed Original file line number Diff line number Diff line change 88 "symfony/filesystem" : " ^2.7 || ^3.4 || ^4.0" ,
99 "twig/twig" : " ^1.41 || ^2.12"
1010 },
11+ "conflict" : {
12+ "drush/drush" : " < 10.3.2"
13+ },
1114 "bin" : [
1215 " bin/dcg"
1316 ],
Original file line number Diff line number Diff line change @@ -51,22 +51,3 @@ function dcg_get_twig_environment($loader) {
5151 }
5252 return $ environment ;
5353}
54-
55- // Determine major Twig version.
56- // \Twig\Environment::MAJOR_VERSION is not suitable here because of
57- // https://github.com/twigphp/Twig/pull/2945
58- // Use this workaround as drupal/drupal is locked on Twig 1.38.
59- list ($ twig_major_version ) = sscanf (Environment::VERSION , '%d.%d.%d ' );
60-
61- // \Twig\Environment::tokenize() signature has been changed in Twig 2, so that
62- // it is not possible to maintain the same \Twig\Environment sub-class for both
63- // Twig versions.
64- $ twig_environment_class = sprintf ('DrupalCodeGenerator\Twig\Twig%dEnvironment ' , $ twig_major_version );
65- if (!class_exists ('DrupalCodeGenerator\Twig\TwigEnvironment ' )) {
66- class_alias ($ twig_environment_class , 'DrupalCodeGenerator\Twig\TwigEnvironment ' );
67- }
68-
69- // Legacy TwigEnvironment class is still used in Drush.
70- if (!class_exists ('DrupalCodeGenerator\TwigEnvironment ' )) {
71- class_alias ($ twig_environment_class , 'DrupalCodeGenerator\TwigEnvironment ' );
72- }
You can’t perform that action at this time.
0 commit comments