Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.Sign up
J3.4.7: Fatal error about connection->stat() not existing on external database connections #8762
When creating an external database connection with JDatabase::getInstance(), it is possible the connection is not created. However since the new Joomla 3.4.7, the disconnect() method (mysqli) tries to check for $this->connection->stat().
I have hacked this solution into my website now:
changed the title
J3.4.7: Error about connection->stat() not existing on external database connections
Dec 22, 2015
Log into admin and then view this url:
The bug produces the error:
After Peter's suggested fix the same page no longer produces an error.
This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/8762.
On this i want to tell you that on some of my sites I'd a similar issue also in joomla < 3.4.7: a warning was issued for 'already closed connection' (i don't remember the exact message) on the
i always put this to prevent it:
We've slightly reworked this check in 3289e7d based on some feedback that we still occasionally got
from the stack trace it seemed to happen in a scenario where either the class was instantiated and never connects (i got it on the first page of the installer, there’s no DB connection at all there) or disconnects before the destructor is called.
I got the Fabrik team to test this as well before committing it. But if any other's in here have any time to check as well all the better :)