-
Notifications
You must be signed in to change notification settings - Fork 5
/
Laravel4ServiceProvider.php
36 lines (32 loc) · 988 Bytes
/
Laravel4ServiceProvider.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
<?php
namespace Michaeljennings\Carpenter;
class Laravel4ServiceProvider extends CarpenterServiceProvider
{
/**
* Bootstrap the application events.
*
* @return void
* @codeCoverageIgnore
*/
public function boot()
{
$this->package('michaeljennings/carpenter', 'carpenter', realpath(__DIR__ . '/../'));
}
/**
* Register the service provider.
*
* @return void
*/
public function register()
{
$this->app->singleton('michaeljennings.carpenter', function ($app) {
return new Carpenter([
'store' => $app['config']['carpenter::store'],
'paginator' => $app['config']['carpenter::paginator'],
'session' => $app['config']['carpenter::session'],
'view' => $app['config']['carpenter::view'],
]);
});
$this->app->alias('michaeljennings.carpenter', 'Michaeljennings\Carpenter\Contracts\Carpenter');
}
}