Skip to content

Commit 4b2d085

Browse files
committed
Check if $db is set before closing.
1 parent 001e971 commit 4b2d085

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/Codeception/Module/Phalcon4.php

+3-1
Original file line numberDiff line numberDiff line change
@@ -209,7 +209,9 @@ public function _after(TestInterface $test)
209209
break;
210210
}
211211
}
212-
$db->close();
212+
if ($db){
213+
$db->close();
214+
}
213215
}
214216
$this->di = null;
215217
Di::reset();

0 commit comments

Comments
 (0)