@@ -4,12 +4,12 @@ discard block |
||
4 | 4 | * Default binding a repository interface to a concret class |
5 | 5 | */ |
6 | 6 | if (!function_exists('bind_contract_repository')) { |
7 | - function bind_contract_repository(string $repositoryInterface, string $repository, string $entity) |
|
7 | + function bind_contract_repository (string $repositoryInterface, string $repository, string $entity) |
|
8 | 8 | { |
9 | 9 | app()->bind($repositoryInterface, function ($app) use ($repository, $entity) { |
10 | 10 | return new $repository( |
11 | - $app['em'], |
|
12 | - $app['em']->getClassMetaData($entity) |
|
11 | + $app[ 'em' ], |
|
12 | + $app[ 'em' ]->getClassMetaData($entity) |
|
13 | 13 | ); |
14 | 14 | }); |
15 | 15 | } |
@@ -19,7 +19,7 @@ discard block |
||
19 | 19 | /** |
20 | 20 | * @param string $className |
21 | 21 | */ |
22 | - function bdEntityName(string $className) |
|
22 | + function bdEntityName (string $className) |
|
23 | 23 | { |
24 | 24 | return config('bludata.generator.rootNamespace').'Entities\\'.$className; |
25 | 25 | } |
@@ -29,7 +29,7 @@ discard block |
||
29 | 29 | /** |
30 | 30 | * @param string $className |
31 | 31 | */ |
32 | - function bdEntity(string $className) |
|
32 | + function bdEntity (string $className) |
|
33 | 33 | { |
34 | 34 | return app(bdEntityName($className)); |
35 | 35 | } |
@@ -39,7 +39,7 @@ discard block |
||
39 | 39 | /** |
40 | 40 | * @param string $className |
41 | 41 | */ |
42 | - function bdContractName(string $className) |
|
42 | + function bdContractName (string $className) |
|
43 | 43 | { |
44 | 44 | return config('bludata.generator.rootNamespace').'Contracts\Repositories\\'.$className.'RepositoryContract'; |
45 | 45 | } |
@@ -49,7 +49,7 @@ discard block |
||
49 | 49 | /** |
50 | 50 | * @param string $className |
51 | 51 | */ |
52 | - function bdRepositoryName(string $className) |
|
52 | + function bdRepositoryName (string $className) |
|
53 | 53 | { |
54 | 54 | return config('bludata.generator.rootNamespace').'Repositories\\'.$className.'Repository'; |
55 | 55 | } |
@@ -59,7 +59,7 @@ discard block |
||
59 | 59 | /** |
60 | 60 | * @param string $className |
61 | 61 | */ |
62 | - function bdRepository(string $className) |
|
62 | + function bdRepository (string $className) |
|
63 | 63 | { |
64 | 64 | return app(bdContractName($className)); |
65 | 65 | } |