Skip to content

Remove fixDIInit in AllConfig #15005

Closed
Closed

Description

@MorrisJobke

Wrap your head around all these different setup paths in base.php and resolve

/**
* TODO - FIXME This fixes an issue with base.php that cause cyclic
* dependencies, especially with autoconfig setup
*
* Replace this by properly injected database connection. Currently the
* base.php triggers the getDatabaseConnection too early which causes in
* autoconfig setup case a too early distributed database connection and
* the autoconfig then needs to reinit all already initialized dependencies
* that use the database connection.
*
* otherwise a SQLite database is created in the wrong directory
* because the database connection was created with an uninitialized config
*/
private function fixDIInit() {
if($this->connection === null) {
$this->connection = \OC::$server->getDatabaseConnection();
}
}

Activity

  1. MorrisJobke commented on Mar 18, 2015

    @MorrisJobke
    ContributorAuthor
  2. added this to the backlog milestone on Mar 1, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions