You are here

public function Poll::isClosed in Poll 8

Returns if the poll is closed.

Return value

bool TRUE if the poll is closed.

Overrides PollInterface::isClosed

File

src/Entity/Poll.php, line 177

Class

Poll
Defines the poll entity class.

Namespace

Drupal\poll\Entity

Code

public function isClosed() {
  return (bool) $this
    ->get('status')->value == 0;
}