Issues (564)

Security Analysis    not enabled

This project does not seem to handle request data directly as such no vulnerable execution paths were found.

  Cross-Site Scripting
Cross-Site Scripting enables an attacker to inject code into the response of a web-request that is viewed by other users. It can for example be used to bypass access controls, or even to take over other users' accounts.
  File Exposure
File Exposure allows an attacker to gain access to local files that he should not be able to access. These files can for example include database credentials, or other configuration files.
  File Manipulation
File Manipulation enables an attacker to write custom data to files. This potentially leads to injection of arbitrary code on the server.
  Object Injection
Object Injection enables an attacker to inject an object into PHP code, and can lead to arbitrary code execution, file exposure, or file manipulation attacks.
  Code Injection
Code Injection enables an attacker to execute arbitrary code on the server.
  Response Splitting
Response Splitting can be used to send arbitrary responses.
  File Inclusion
File Inclusion enables an attacker to inject custom files into PHP's file loading mechanism, either explicitly passed to include, or for example via PHP's auto-loading mechanism.
  Command Injection
Command Injection enables an attacker to inject a shell command that is execute with the privileges of the web-server. This can be used to expose sensitive data, or gain access of your server.
  SQL Injection
SQL Injection enables an attacker to execute arbitrary SQL code on your database server gaining access to user data, or manipulating user data.
  XPath Injection
XPath Injection enables an attacker to modify the parts of XML document that are read. If that XML document is for example used for authentication, this can lead to further vulnerabilities similar to SQL Injection.
  LDAP Injection
LDAP Injection enables an attacker to inject LDAP statements potentially granting permission to run unauthorized queries, or modify content inside the LDAP tree.
  Header Injection
  Other Vulnerability
This category comprises other attack vectors such as manipulating the PHP runtime, loading custom extensions, freezing the runtime, or similar.
  Regex Injection
Regex Injection enables an attacker to execute arbitrary code in your PHP process.
  XML Injection
XML Injection enables an attacker to read files on your local filesystem including configuration files, or can be abused to freeze your web-server process.
  Variable Injection
Variable Injection enables an attacker to overwrite program variables with custom data, and can lead to further vulnerabilities.
Unfortunately, the security analysis is currently not available for your project. If you are a non-commercial open-source project, please contact support to gain access.

Eccube/ServiceProvider/EccubeServiceProvider.php (17 issues)

Upgrade to new PHP Analysis Engine

These results are based on our legacy PHP analysis, consider migrating to our new PHP analysis engine instead. Learn more

1
<?php
2
/*
3
 * This file is part of EC-CUBE
4
 *
5
 * Copyright(c) EC-CUBE CO.,LTD. All Rights Reserved.
6
 *
7
 * http://www.ec-cube.co.jp/
8
 *
9
 * This program is free software; you can redistribute it and/or
10
 * modify it under the terms of the GNU General Public License
11
 * as published by the Free Software Foundation; either version 2
12
 * of the License, or (at your option) any later version.
13
 *
14
 * This program is distributed in the hope that it will be useful,
15
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
17
 * GNU General Public License for more details.
18
 *
19
 * You should have received a copy of the GNU General Public License
20
 * along with this program; if not, write to the Free Software
21
 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
22
 */
23
24
25
namespace Eccube\ServiceProvider;
26
27
use Eccube\Application;
28
use Silex\Application as BaseApplication;
29
use Silex\ServiceProviderInterface;
30
31
class EccubeServiceProvider implements ServiceProviderInterface
32
{
33
    /**
34
     * Registers services on the given app.
35
     *
36
     * This method should only be used to configure services and parameters.
37
     * It should not get services.
38
     *
39
     * @param BaseApplication $app An Application instance
40
     */
41
    public function register(BaseApplication $app)
42
    {
43
        // Service
44
        $app['eccube.service.system'] = $app->share(function () use ($app) {
45
            return new \Eccube\Service\SystemService($app);
0 ignored issues
show
$app of type object<Silex\Application> is not a sub-type of object<Eccube\Application>. It seems like you assume a child class of the class Silex\Application to be always present.

This check looks for parameters that are defined as one type in their type hint or doc comment but seem to be used as a narrower type, i.e an implementation of an interface or a subclass.

Consider changing the type of the parameter or doing an instanceof check before assuming your parameter is of the expected type.

Loading history...
46
        });
47
        $app['view'] = $app->share(function () use ($app) {
48
            return $app['twig'];
49
        });
50
        $app['eccube.service.cart'] = $app->share(function () use ($app) {
51
            return new \Eccube\Service\CartService($app);
0 ignored issues
show
$app of type object<Silex\Application> is not a sub-type of object<Eccube\Application>. It seems like you assume a child class of the class Silex\Application to be always present.

This check looks for parameters that are defined as one type in their type hint or doc comment but seem to be used as a narrower type, i.e an implementation of an interface or a subclass.

Consider changing the type of the parameter or doing an instanceof check before assuming your parameter is of the expected type.

Loading history...
52
        });
53
        $app['eccube.service.order'] = $app->share(function () use ($app) {
54
            return new \Eccube\Service\OrderService($app);
0 ignored issues
show
$app of type object<Silex\Application> is not a sub-type of object<Eccube\Application>. It seems like you assume a child class of the class Silex\Application to be always present.

This check looks for parameters that are defined as one type in their type hint or doc comment but seem to be used as a narrower type, i.e an implementation of an interface or a subclass.

Consider changing the type of the parameter or doing an instanceof check before assuming your parameter is of the expected type.

Loading history...
Deprecated Code introduced by
The class Eccube\Service\OrderService has been deprecated with message: since 3.0.0, to be removed in 3.1

This class, trait or interface has been deprecated. The supplier of the file has supplied an explanatory message.

The explanatory message should give you some clue as to whether and when the type will be removed from the class and what other constant to use instead.

Loading history...
55
        });
56
        $app['eccube.service.tax_rule'] = $app->share(function () use ($app) {
57
            return new \Eccube\Service\TaxRuleService($app['eccube.repository.tax_rule']);
58
        });
59
        $app['eccube.service.plugin'] = $app->share(function () use ($app) {
60
            return new \Eccube\Service\PluginService($app);
61
        });
62
        $app['eccube.service.mail'] = $app->share(function () use ($app) {
63
            return new \Eccube\Service\MailService($app);
0 ignored issues
show
$app of type object<Silex\Application> is not a sub-type of object<Eccube\Application>. It seems like you assume a child class of the class Silex\Application to be always present.

This check looks for parameters that are defined as one type in their type hint or doc comment but seem to be used as a narrower type, i.e an implementation of an interface or a subclass.

Consider changing the type of the parameter or doing an instanceof check before assuming your parameter is of the expected type.

Loading history...
64
        });
65
        $app['eccube.service.csv.export'] = $app->share(function () use ($app) {
66
            $csvService = new \Eccube\Service\CsvExportService();
67
            $csvService->setEntityManager($app['orm.em']);
68
            $csvService->setConfig($app['config']);
69
            $csvService->setCsvRepository($app['eccube.repository.csv']);
70
            $csvService->setCsvTypeRepository($app['eccube.repository.master.csv_type']);
71
            $csvService->setOrderRepository($app['eccube.repository.order']);
72
            $csvService->setCustomerRepository($app['eccube.repository.customer']);
73
            $csvService->setProductRepository($app['eccube.repository.product']);
74
75
            return $csvService;
76
        });
77
        $app['eccube.service.shopping'] = $app->share(function () use ($app) {
78
            return new \Eccube\Service\ShoppingService($app, $app['eccube.service.cart'], $app['eccube.service.order']);
0 ignored issues
show
$app of type object<Silex\Application> is not a sub-type of object<Eccube\Application>. It seems like you assume a child class of the class Silex\Application to be always present.

This check looks for parameters that are defined as one type in their type hint or doc comment but seem to be used as a narrower type, i.e an implementation of an interface or a subclass.

Consider changing the type of the parameter or doing an instanceof check before assuming your parameter is of the expected type.

Loading history...
79
        });
80
81
        // Repository
82
        $app['eccube.repository.master.authority'] = $app->share(function () use ($app) {
83
            return $app['orm.em']->getRepository('Eccube\Entity\Master\Authority');
84
        });
85
        $app['eccube.repository.master.tag'] = $app->share(function () use ($app) {
86
            return $app['orm.em']->getRepository('Eccube\Entity\Master\Tag');
87
        });
88
        $app['eccube.repository.master.pref'] = $app->share(function () use ($app) {
89
            return $app['orm.em']->getRepository('Eccube\Entity\Master\Pref');
90
        });
91
        $app['eccube.repository.master.sex'] = $app->share(function () use ($app) {
92
            return $app['orm.em']->getRepository('Eccube\Entity\Master\Sex');
93
        });
94
        $app['eccube.repository.master.disp'] = $app->share(function () use ($app) {
95
            return $app['orm.em']->getRepository('Eccube\Entity\Master\Disp');
96
        });
97
        $app['eccube.repository.master.product_type'] = $app->share(function () use ($app) {
98
            return $app['orm.em']->getRepository('Eccube\Entity\Master\ProductType');
99
        });
100
        $app['eccube.repository.master.page_max'] = $app->share(function () use ($app) {
101
            return $app['orm.em']->getRepository('Eccube\Entity\Master\PageMax');
102
        });
103
        $app['eccube.repository.master.product_list_max'] = $app->share(function () use ($app) {
104
            return $app['orm.em']->getRepository('Eccube\Entity\Master\ProductListMax');
105
        });
106
        $app['eccube.repository.master.product_list_order_by'] = $app->share(function () use ($app) {
107
            return $app['orm.em']->getRepository('Eccube\Entity\Master\ProductListOrderBy');
108
        });
109
        $app['eccube.repository.master.order_status'] = $app->share(function () use ($app) {
110
            return $app['orm.em']->getRepository('Eccube\Entity\Master\OrderStatus');
111
        });
112
        $app['eccube.repository.master.device_type'] = $app->share(function () use ($app) {
113
            return $app['orm.em']->getRepository('Eccube\Entity\Master\DeviceType');
114
        });
115
        $app['eccube.repository.master.csv_type'] = $app->share(function () use ($app) {
116
            return $app['orm.em']->getRepository('Eccube\Entity\Master\CsvType');
117
        });
118
119
        $app['eccube.repository.delivery'] = $app->share(function () use ($app) {
120
            return $app['orm.em']->getRepository('Eccube\Entity\Delivery');
121
        });
122
        $app['eccube.repository.delivery_date'] = $app->share(function () use ($app) {
123
            return $app['orm.em']->getRepository('Eccube\Entity\DeliveryDate');
124
        });
125
        $app['eccube.repository.delivery_fee'] = $app->share(function () use ($app) {
126
            return $app['orm.em']->getRepository('Eccube\Entity\DeliveryFee');
127
        });
128
        $app['eccube.repository.delivery_time'] = $app->share(function () use ($app) {
129
            return $app['orm.em']->getRepository('Eccube\Entity\DeliveryTime');
130
        });
131
        $app['eccube.repository.payment'] = $app->share(function () use ($app) {
132
            return $app['orm.em']->getRepository('Eccube\Entity\Payment');
133
        });
134
        $app['eccube.repository.payment_option'] = $app->share(function () use ($app) {
135
            return $app['orm.em']->getRepository('Eccube\Entity\PaymentOption');
136
        });
137
        $app['eccube.repository.category'] = $app->share(function () use ($app) {
138
            $CategoryRepository = $app['orm.em']->getRepository('Eccube\Entity\Category');
139
            $CategoryRepository->setApplication($app);
140
141
            return $CategoryRepository;
142
        });
143
        $app['eccube.repository.customer'] = $app->share(function () use ($app) {
144
            return $app['orm.em']->getRepository('Eccube\Entity\Customer');
145
        });
146
        $app['eccube.repository.news'] = $app->share(function () use ($app) {
147
            return $app['orm.em']->getRepository('Eccube\Entity\News');
148
        });
149
        $app['eccube.repository.mail_history'] = $app->share(function () use ($app) {
150
            return $app['orm.em']->getRepository('Eccube\Entity\MailHistory');
151
        });
152
        $app['eccube.repository.member'] = $app->share(function () use ($app) {
153
            $memberRepository = $app['orm.em']->getRepository('Eccube\Entity\Member');
154
            $memberRepository->setEncoderFactorty($app['security.encoder_factory']);
155
            return $memberRepository;
156
        });
157
        $app['eccube.repository.order'] = $app->share(function () use ($app) {
158
            return $app['orm.em']->getRepository('Eccube\Entity\Order');
159
        });
160
        $app['eccube.repository.product'] = $app->share(function () use ($app) {
161
            $productRepository = $app['orm.em']->getRepository('Eccube\Entity\Product');
162
            $productRepository->setApplication($app);
163
164
            return $productRepository;
165
        });
166
        $app['eccube.repository.product_image'] = $app->share(function () use ($app) {
167
            return $app['orm.em']->getRepository('Eccube\Entity\ProductImage');
168
        });
169
        $app['eccube.repository.product_class'] = $app->share(function () use ($app) {
170
            return $app['orm.em']->getRepository('Eccube\Entity\ProductClass');
171
        });
172
        $app['eccube.repository.product_stock'] = $app->share(function () use ($app) {
173
            return $app['orm.em']->getRepository('Eccube\Entity\ProductStock');
174
        });
175
        $app['eccube.repository.product_tag'] = $app->share(function () use ($app) {
176
            return $app['orm.em']->getRepository('Eccube\Entity\ProductTag');
177
        });
178
        $app['eccube.repository.class_name'] = $app->share(function () use ($app) {
179
            return $app['orm.em']->getRepository('Eccube\Entity\ClassName');
180
        });
181
        $app['eccube.repository.class_category'] = $app->share(function () use ($app) {
182
            return $app['orm.em']->getRepository('Eccube\Entity\ClassCategory');
183
        });
184
        $app['eccube.repository.customer_favorite_product'] = $app->share(function () use ($app) {
185
            return $app['orm.em']->getRepository('Eccube\Entity\CustomerFavoriteProduct');
186
        });
187
        $app['eccube.repository.base_info'] = $app->share(function () use ($app) {
188
            $BaseInfoRepository = $app['orm.em']->getRepository('Eccube\Entity\BaseInfo');
189
            $BaseInfoRepository->setApplication($app);
190
191
            return $BaseInfoRepository;
192
        });
193
        $app['eccube.repository.tax_rule'] = $app->share(function () use ($app) {
194
            $taxRuleRepository = $app['orm.em']->getRepository('Eccube\Entity\TaxRule');
195
            $taxRuleRepository->setApplication($app);
196
197
            return $taxRuleRepository;
198
        });
199
        $app['eccube.repository.page_layout'] = $app->share(function () use ($app) {
200
            $pageLayoutRepository = $app['orm.em']->getRepository('Eccube\Entity\PageLayout');
201
            $pageLayoutRepository->setApplication($app);
202
203
            return $pageLayoutRepository;
204
        });
205
        $app['eccube.repository.block'] = $app->share(function () use ($app) {
206
            $blockRepository = $app['orm.em']->getRepository('Eccube\Entity\Block');
207
            $blockRepository->setApplication($app);
208
209
            return $blockRepository;
210
        });
211
        $app['eccube.repository.block_position'] = $app->share(function () use ($app) {
212
            return $app['orm.em']->getRepository('Eccube\Entity\BlockPosition');
213
        });
214
        $app['eccube.repository.order'] = $app->share(function () use ($app) {
215
            $orderRepository = $app['orm.em']->getRepository('Eccube\Entity\Order');
216
            $orderRepository->setApplication($app);
217
218
            return $orderRepository;
219
        });
220
        $app['eccube.repository.customer_address'] = $app->share(function () use ($app) {
221
            return $app['orm.em']->getRepository('Eccube\Entity\CustomerAddress');
222
        });
223
        $app['eccube.repository.shipping'] = $app->share(function () use ($app) {
224
            return $app['orm.em']->getRepository('Eccube\Entity\Shipping');
225
        });
226
        $app['eccube.repository.customer_status'] = $app->share(function () use ($app) {
227
            return $app['orm.em']->getRepository('Eccube\Entity\Master\CustomerStatus');
228
        });
229
        $app['eccube.repository.order_status'] = $app->share(function () use ($app) {
230
            return $app['orm.em']->getRepository('Eccube\Entity\Master\OrderStatus');
231
        });
232
        $app['eccube.repository.mail_template'] = $app->share(function () use ($app) {
233
            return $app['orm.em']->getRepository('Eccube\Entity\MailTemplate');
234
        });
235
        $app['eccube.repository.csv'] = $app->share(function () use ($app) {
236
            return $app['orm.em']->getRepository('Eccube\Entity\Csv');
237
        });
238
        $app['eccube.repository.template'] = $app->share(function () use ($app) {
239
            return $app['orm.em']->getRepository('Eccube\Entity\Template');
240
        });
241
        $app['eccube.repository.authority_role'] = $app->share(function () use ($app) {
242
            return $app['orm.em']->getRepository('Eccube\Entity\AuthorityRole');
243
        });
244
245
        $app['paginator'] = $app->protect(function () {
246
            $paginator = new \Knp\Component\Pager\Paginator();
247
            $paginator->subscribe(new \Eccube\EventListener\PaginatorListener());
248
249
            return $paginator;
250
        });
251
252
        $app['eccube.repository.help'] = $app->share(function () use ($app) {
253
            return $app['orm.em']->getRepository('Eccube\Entity\Help');
254
        });
255
        $app['eccube.repository.plugin'] = $app->share(function () use ($app) {
256
            return $app['orm.em']->getRepository('Eccube\Entity\Plugin');
257
        });
258
        $app['eccube.repository.plugin_event_handler'] = $app->share(function () use ($app) {
259
            return $app['orm.em']->getRepository('Eccube\Entity\PluginEventHandler');
260
        });
261
        // em
262
        if (isset($app['orm.em'])) {
263
            $app['orm.em'] = $app->share($app->extend('orm.em', function (\Doctrine\ORM\EntityManager $em, \Silex\Application $app) {
264
                // tax_rule
265
                $taxRuleRepository = $em->getRepository('Eccube\Entity\TaxRule');
266
                $taxRuleRepository->setApplication($app);
267
                $taxRuleService = new \Eccube\Service\TaxRuleService($taxRuleRepository);
0 ignored issues
show
$taxRuleRepository of type object<Doctrine\ORM\EntityRepository> is not a sub-type of object<Eccube\Repository\TaxRuleRepository>. It seems like you assume a child class of the class Doctrine\ORM\EntityRepository to be always present.

This check looks for parameters that are defined as one type in their type hint or doc comment but seem to be used as a narrower type, i.e an implementation of an interface or a subclass.

Consider changing the type of the parameter or doing an instanceof check before assuming your parameter is of the expected type.

Loading history...
268
                $em->getEventManager()->addEventSubscriber(new \Eccube\Doctrine\EventSubscriber\TaxRuleEventSubscriber($taxRuleService));
269
270
                // save
271
                $saveEventSubscriber = new \Eccube\Doctrine\EventSubscriber\SaveEventSubscriber($app);
0 ignored issues
show
$app of type object<Silex\Application> is not a sub-type of object<Eccube\Application>. It seems like you assume a child class of the class Silex\Application to be always present.

This check looks for parameters that are defined as one type in their type hint or doc comment but seem to be used as a narrower type, i.e an implementation of an interface or a subclass.

Consider changing the type of the parameter or doing an instanceof check before assuming your parameter is of the expected type.

Loading history...
272
                $em->getEventManager()->addEventSubscriber($saveEventSubscriber);
273
274
                // clear cache
275
                $clearCacheEventSubscriber = new \Eccube\Doctrine\EventSubscriber\ClearCacheEventSubscriber($app);
0 ignored issues
show
$app of type object<Silex\Application> is not a sub-type of object<Eccube\Application>. It seems like you assume a child class of the class Silex\Application to be always present.

This check looks for parameters that are defined as one type in their type hint or doc comment but seem to be used as a narrower type, i.e an implementation of an interface or a subclass.

Consider changing the type of the parameter or doing an instanceof check before assuming your parameter is of the expected type.

Loading history...
276
                $em->getEventManager()->addEventSubscriber($clearCacheEventSubscriber);
277
278
                // filters
279
                $config = $em->getConfiguration();
280
                $config->addFilter("soft_delete", '\Eccube\Doctrine\Filter\SoftDeleteFilter');
281
                $config->addFilter("nostock_hidden", '\Eccube\Doctrine\Filter\NoStockHiddenFilter');
282
                $config->addFilter("incomplete_order_status_hidden", '\Eccube\Doctrine\Filter\OrderStatusFilter');
283
                $em->getFilters()->enable('soft_delete');
284
285
                return $em;
286
            }));
287
        }
288
289
        // Form\Type
290
        $app['form.type.extensions'] = $app->share($app->extend('form.type.extensions', function ($extensions) use ($app) {
291
            $extensions[] = new \Eccube\Form\Extension\HelpTypeExtension();
292
            $extensions[] = new \Eccube\Form\Extension\FreezeTypeExtension();
293
294
            return $extensions;
295
        }));
296
        $app['form.types'] = $app->share($app->extend('form.types', function ($types) use ($app) {
297
            $types[] = new \Eccube\Form\Type\NameType($app['config']);
298
            $types[] = new \Eccube\Form\Type\KanaType($app['config']);
299
            $types[] = new \Eccube\Form\Type\TelType($app['config']);
300
            $types[] = new \Eccube\Form\Type\FaxType(); // 削除予定
301
            $types[] = new \Eccube\Form\Type\ZipType($app['config']);
302
            $types[] = new \Eccube\Form\Type\AddressType($app['config']);
303
            $types[] = new \Eccube\Form\Type\RepeatedEmailType();
304
            $types[] = new \Eccube\Form\Type\RepeatedPasswordType($app['config']);
305
            $types[] = new \Eccube\Form\Type\PriceType($app['config']);
306
307
            $types[] = new \Eccube\Form\Type\MasterType();
308
            $types[] = new \Eccube\Form\Type\Master\JobType();
309
            $types[] = new \Eccube\Form\Type\Master\CustomerStatusType();
310
            $types[] = new \Eccube\Form\Type\Master\OrderStatusType();
311
            $types[] = new \Eccube\Form\Type\Master\CalcRuleType();
312
            $types[] = new \Eccube\Form\Type\Master\SexType();
313
            $types[] = new \Eccube\Form\Type\Master\DispType();
314
            $types[] = new \Eccube\Form\Type\Master\PrefType();
315
            $types[] = new \Eccube\Form\Type\Master\ProductTypeType();
316
            $types[] = new \Eccube\Form\Type\Master\ProductListMaxType();
317
            $types[] = new \Eccube\Form\Type\Master\ProductListOrderByType();
318
            $types[] = new \Eccube\Form\Type\Master\PageMaxType();
319
            $types[] = new \Eccube\Form\Type\Master\CsvType();
320
            $types[] = new \Eccube\Form\Type\Master\DeliveryDateType();
321
            $types[] = new \Eccube\Form\Type\Master\PaymentType();
322
            $types[] = new \Eccube\Form\Type\Master\MailTemplateType();
323
            $types[] = new \Eccube\Form\Type\Master\CategoryType();
324
            $types[] = new \Eccube\Form\Type\Master\TagType();
325
326
            $types[] = new \Eccube\Form\Type\CustomerType($app); // 削除予定
327
328
            if (isset($app['security']) && isset($app['eccube.repository.customer_favorite_product'])) {
329
                $types[] = new \Eccube\Form\Type\AddCartType($app['config'], $app['security'], $app['eccube.repository.customer_favorite_product']);
330
            }
331
            $types[] = new \Eccube\Form\Type\SearchProductType($app);
0 ignored issues
show
$app of type object<Silex\Application> is not a sub-type of object<Eccube\Application>. It seems like you assume a child class of the class Silex\Application to be always present.

This check looks for parameters that are defined as one type in their type hint or doc comment but seem to be used as a narrower type, i.e an implementation of an interface or a subclass.

Consider changing the type of the parameter or doing an instanceof check before assuming your parameter is of the expected type.

Loading history...
332
            $types[] = new \Eccube\Form\Type\SearchProductBlockType($app);
0 ignored issues
show
$app of type object<Silex\Application> is not a sub-type of object<Eccube\Application>. It seems like you assume a child class of the class Silex\Application to be always present.

This check looks for parameters that are defined as one type in their type hint or doc comment but seem to be used as a narrower type, i.e an implementation of an interface or a subclass.

Consider changing the type of the parameter or doing an instanceof check before assuming your parameter is of the expected type.

Loading history...
333
            $types[] = new \Eccube\Form\Type\OrderSearchType($app);
334
            $types[] = new \Eccube\Form\Type\ShippingItemType($app);
0 ignored issues
show
$app of type object<Silex\Application> is not a sub-type of object<Eccube\Application>. It seems like you assume a child class of the class Silex\Application to be always present.

This check looks for parameters that are defined as one type in their type hint or doc comment but seem to be used as a narrower type, i.e an implementation of an interface or a subclass.

Consider changing the type of the parameter or doing an instanceof check before assuming your parameter is of the expected type.

Loading history...
335
            $types[] = new \Eccube\Form\Type\ShippingMultipleType($app);
0 ignored issues
show
$app of type object<Silex\Application> is not a sub-type of object<Eccube\Application>. It seems like you assume a child class of the class Silex\Application to be always present.

This check looks for parameters that are defined as one type in their type hint or doc comment but seem to be used as a narrower type, i.e an implementation of an interface or a subclass.

Consider changing the type of the parameter or doing an instanceof check before assuming your parameter is of the expected type.

Loading history...
336
            $types[] = new \Eccube\Form\Type\ShippingMultipleItemType($app);
0 ignored issues
show
$app of type object<Silex\Application> is not a sub-type of object<Eccube\Application>. It seems like you assume a child class of the class Silex\Application to be always present.

This check looks for parameters that are defined as one type in their type hint or doc comment but seem to be used as a narrower type, i.e an implementation of an interface or a subclass.

Consider changing the type of the parameter or doing an instanceof check before assuming your parameter is of the expected type.

Loading history...
337
            $types[] = new \Eccube\Form\Type\ShoppingType();
338
339
            // front
340
            $types[] = new \Eccube\Form\Type\Front\EntryType($app['config']);
341
            $types[] = new \Eccube\Form\Type\Front\ContactType($app['config']);
342
            $types[] = new \Eccube\Form\Type\Front\NonMemberType($app['config']);
343
            $types[] = new \Eccube\Form\Type\Front\ShoppingShippingType();
344
            $types[] = new \Eccube\Form\Type\Front\CustomerAddressType($app['config']);
345
            $types[] = new \Eccube\Form\Type\Front\ForgotType();
346
            $types[] = new \Eccube\Form\Type\Front\CustomerLoginType($app['session']);
347
348
            // admin
349
            $types[] = new \Eccube\Form\Type\Admin\LoginType($app['session']);
350
            $types[] = new \Eccube\Form\Type\Admin\ChangePasswordType($app);
351
            $types[] = new \Eccube\Form\Type\Admin\ProductType($app);
0 ignored issues
show
$app of type object<Silex\Application> is not a sub-type of object<Eccube\Application>. It seems like you assume a child class of the class Silex\Application to be always present.

This check looks for parameters that are defined as one type in their type hint or doc comment but seem to be used as a narrower type, i.e an implementation of an interface or a subclass.

Consider changing the type of the parameter or doing an instanceof check before assuming your parameter is of the expected type.

Loading history...
352
            $types[] = new \Eccube\Form\Type\Admin\ProductClassType($app);
353
            $types[] = new \Eccube\Form\Type\Admin\SearchProductType($app);
354
            $types[] = new \Eccube\Form\Type\Admin\SearchCustomerType($app['config']);
355
            $types[] = new \Eccube\Form\Type\Admin\SearchOrderType($app['config']);
356
            $types[] = new \Eccube\Form\Type\Admin\CustomerType($app['config']);
357
            $types[] = new \Eccube\Form\Type\Admin\ClassNameType($app['config']);
358
            $types[] = new \Eccube\Form\Type\Admin\ClassCategoryType($app['config']);
359
            $types[] = new \Eccube\Form\Type\Admin\CategoryType($app['config']);
360
            $types[] = new \Eccube\Form\Type\Admin\MemberType($app['config']);
361
            $types[] = new \Eccube\Form\Type\Admin\AuthorityRoleType($app['config']);
362
            $types[] = new \Eccube\Form\Type\Admin\PageLayoutType();
363
            $types[] = new \Eccube\Form\Type\Admin\NewsType($app['config']);
364
            $types[] = new \Eccube\Form\Type\Admin\TemplateType($app['config']);
365
            $types[] = new \Eccube\Form\Type\Admin\SecurityType($app);
366
            $types[] = new \Eccube\Form\Type\Admin\CsvImportType($app);
367
            $types[] = new \Eccube\Form\Type\Admin\ShopMasterType($app['config']);
368
            $types[] = new \Eccube\Form\Type\Admin\TradelawType($app['config']);
369
            $types[] = new \Eccube\Form\Type\Admin\OrderType($app);
370
            $types[] = new \Eccube\Form\Type\Admin\OrderDetailType($app);
371
            $types[] = new \Eccube\Form\Type\Admin\ShippingType($app);
0 ignored issues
show
$app of type object<Silex\Application> is not a sub-type of object<Eccube\Application>. It seems like you assume a child class of the class Silex\Application to be always present.

This check looks for parameters that are defined as one type in their type hint or doc comment but seem to be used as a narrower type, i.e an implementation of an interface or a subclass.

Consider changing the type of the parameter or doing an instanceof check before assuming your parameter is of the expected type.

Loading history...
372
            $types[] = new \Eccube\Form\Type\Admin\ShipmentItemType($app);
373
            $types[] = new \Eccube\Form\Type\Admin\PaymentRegisterType($app);
374
            $types[] = new \Eccube\Form\Type\Admin\TaxRuleType();
375
            $types[] = new \Eccube\Form\Type\Admin\MainEditType($app);
376
            $types[] = new \Eccube\Form\Type\Admin\MailType();
377
            $types[] = new \Eccube\Form\Type\Admin\CustomerAgreementType($app);
378
            $types[] = new \Eccube\Form\Type\Admin\BlockType($app);
379
            $types[] = new \Eccube\Form\Type\Admin\DeliveryType();
380
            $types[] = new \Eccube\Form\Type\Admin\DeliveryFeeType();
381
            $types[] = new \Eccube\Form\Type\Admin\DeliveryTimeType($app['config']);
382
            $types[] = new \Eccube\Form\Type\Admin\LogType($app['config']);
383
            $types[] = new \Eccube\Form\Type\Admin\CacheType($app['config']);
384
385
            $types[] = new \Eccube\Form\Type\Admin\MasterdataType($app);
386
            $types[] = new \Eccube\Form\Type\Admin\MasterdataDataType($app);
0 ignored issues
show
$app of type object<Silex\Application> is not a sub-type of object<Eccube\Application>. It seems like you assume a child class of the class Silex\Application to be always present.

This check looks for parameters that are defined as one type in their type hint or doc comment but seem to be used as a narrower type, i.e an implementation of an interface or a subclass.

Consider changing the type of the parameter or doing an instanceof check before assuming your parameter is of the expected type.

Loading history...
387
            $types[] = new \Eccube\Form\Type\Admin\MasterdataEditType($app);
388
389
            $types[] = new \Eccube\Form\Type\Admin\PluginLocalInstallType();
390
            $types[] = new \Eccube\Form\Type\Admin\PluginManagementType();
391
392
            return $types;
393
        }));
394
    }
395
396
    /**
397
     * Bootstraps the application.
398
     *
399
     * This method is called after all services are registered
400
     * and should be used for "dynamic" configuration (whenever
401
     * a service must be requested).
402
     */
403
    public function boot(BaseApplication $app)
404
    {
405
    }
406
}
407