PHP Fatal error: Uncaught Error: Call to a member function fetch_object() on boolean in