Permalink
Browse files

Stop iterating if we dont have a valid file handle

fixes #34
  • Loading branch information...
icewind1991 committed Dec 22, 2016
1 parent 4d4f589 commit a87a8e653ecae5efef6342e645b98f2878219c87
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/Log/LogIterator.php
View
@@ -102,6 +102,6 @@ function next() {
}
function valid() {
return $this->position >= 0;
return $this->position >= 0 && is_resource($this->handle);
}
}

0 comments on commit a87a8e6

Please sign in to comment.