Conditions | 2 |
Paths | 1 |
Total Lines | 14 |
Code Lines | 11 |
Lines | 0 |
Ratio | 0 % |
Tests | 12 |
CRAP Score | 2 |
Changes | 6 | ||
Bugs | 2 | Features | 3 |
1 | <?php |
||
18 | 1 | public function __construct (array $urlParams=array()) { |
|
19 | 1 | parent::__construct('mail', $urlParams); |
|
20 | |||
21 | 1 | $container = $this->getContainer(); |
|
22 | 1 | $transport = $container->getServer()->getConfig()->getSystemValue('app.mail.transport', 'smtp'); |
|
23 | 1 | $testSmtp = $transport === 'smtp'; |
|
24 | |||
25 | 1 | $user = $container->query("UserId"); |
|
26 | 1 | $container->registerParameter("appName", "mail"); |
|
27 | 1 | $container->registerParameter("userFolder", $container->getServer()->getUserFolder($user)); |
|
28 | 1 | $container->registerParameter("testSmtp", $testSmtp); |
|
29 | 1 | $container->registerParameter("referrer", isset($_SERVER['HTTP_REFERER']) ? : null); |
|
30 | 1 | $container->registerParameter("hostname", \OCP\Util::getServerHostName()); |
|
31 | 1 | } |
|
32 | |||
34 |