Skip to content

Commit 4a9b899

Browse files
nidenJeckerson
andauthored
Update phalcon/Logger/Adapter/Stream.zep
Co-authored-by: Anton Vasiliev <Jeckerson@users.noreply.github.com>
1 parent 1fa0dad commit 4a9b899

File tree

1 file changed

+4
-9
lines changed

1 file changed

+4
-9
lines changed

phalcon/Logger/Adapter/Stream.zep

Lines changed: 4 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -93,17 +93,12 @@ class Stream extends AbstractAdapter
9393
*/
9494
public function close() -> bool
9595
{
96-
var result;
97-
98-
let result = true;
99-
100-
if (is_resource(this->handler)) {
101-
let result = this->phpFclose(this->handler);
96+
if (this->handler !== null) {
97+
let this->handler = null;
98+
return this->phpFclose(this->handler);
10299
}
103100

104-
let this->handler = null;
105-
106-
return result;
101+
return true;
107102
}
108103

109104
/**

0 commit comments

Comments
 (0)