Skip to content
This repository was archived by the owner on Jan 31, 2020. It is now read-only.

Commit 300ec1f

Browse files
committed
Merge branch 'improvement/19'
Close #19
2 parents 14c6504 + fe9db26 commit 300ec1f

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/Table/Row.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ public function render(array $columnWidths, Decorator $decorator, $padding = 0)
125125

126126
// If there is no single column, create a column which spans over the
127127
// entire row
128-
if (count($this->columns) === 0) {
128+
if (! $this->columns) {
129129
$this->appendColumn(new Column(null, null, count($columnWidths)));
130130
}
131131

src/Table/Table.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,7 @@ public function setOptions(array $options)
157157
*/
158158
public function setColumnWidths(array $columnWidths)
159159
{
160-
if (count($columnWidths) === 0) {
160+
if (! $columnWidths) {
161161
throw new Exception\InvalidArgumentException('You must supply at least one column');
162162
}
163163

@@ -342,7 +342,7 @@ public function appendRow($row)
342342
public function render()
343343
{
344344
// There should be at least one row
345-
if (count($this->rows) === 0) {
345+
if (! $this->rows) {
346346
throw new Exception\UnexpectedValueException('No rows were added to the table yet');
347347
}
348348

0 commit comments

Comments
 (0)