Completed
Pull Request — master (#594)
by Mateusz
03:09
created

DeploynautPsrOutputAdapter::log()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 1
Metric Value
c 1
b 0
f 1
dl 0
loc 3
rs 10
cc 1
eloc 2
nc 1
nop 3
1
<?php
2
3
/**
4
 * Adapt DeploynautLogFile logger to work as a PSR logger.
5
 */
6
class DeploynautPsrOutputAdapter extends \Psr\Log\AbstractLogger {
7
8
	/**
9
	 * @var DeploynautLogFile
10
	 */
11
	protected $log;
12
13
	public function __construct(DeploynautLogFile $log) {
14
		$this->log = $log;
15
	}
16
17
	public function log($level, $message, array $context = []) {
18
		$this->log->write($message);
19
	}
20
}
21
22