-
Notifications
You must be signed in to change notification settings - Fork 48
Expand file tree
/
Copy pathBootstrap.php
More file actions
38 lines (31 loc) · 788 Bytes
/
Bootstrap.php
File metadata and controls
38 lines (31 loc) · 788 Bytes
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
37
38
<?php
/**
/**
* Mail Command Controller
*
* @author Rochdi B. <rochdi80tn@gmail.com>
*/
namespace nterms\mailqueue;
use yii\base\Application;
use yii\base\BootstrapInterface;
/**
* Class Bootstrap
*
* @package nterms\mailqueue;
* @author Rochdi B. <rochdi80tn@gmail.com>
*/
class Bootstrap implements BootstrapInterface
{
/**
* Bootstrap method to be called during application bootstrap stage.
* Will add the mailqueue command to the controller map
*
* @param Application $app the application currently running
*/
public function bootstrap($app)
{
if ($app instanceof \yii\console\Application) {
$app->controllerMap['mailqueue'] = 'nterms\mailqueue\commands\MailQueueController';
}
}
}