Skip to content

Commit 46958e4

Browse files
authored
Merge pull request #7608 from nextcloud/pimp_timestampformatter
Fixes for TimestampFormatter
2 parents e37fa60 + 735b9fb commit 46958e4

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

lib/private/Console/TimestampFormatter.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,9 @@ class TimestampFormatter implements OutputFormatterInterface {
3131
/** @var IConfig */
3232
protected $config;
3333

34+
/** @var OutputFormatterInterface */
35+
protected $formatter;
36+
3437
/**
3538
* @param IConfig $config
3639
* @param OutputFormatterInterface $formatter
@@ -75,14 +78,15 @@ public function setStyle($name, OutputFormatterStyleInterface $style) {
7578
* @return bool
7679
*/
7780
public function hasStyle($name) {
78-
$this->formatter->hasStyle($name);
81+
return $this->formatter->hasStyle($name);
7982
}
8083

8184
/**
8285
* Gets style options from style with specified name.
8386
*
8487
* @param string $name
8588
* @return OutputFormatterStyleInterface
89+
* @throws \InvalidArgumentException When style isn't defined
8690
*/
8791
public function getStyle($name) {
8892
return $this->formatter->getStyle($name);

0 commit comments

Comments
 (0)