Doctrine 1
  1. Doctrine 1
  2. DC-681

Command-line option rebuild-db is touching the models

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.2.2
    • Fix Version/s: 1.2.3
    • Component/s: Cli
    • Labels:
      None

      Description

      The command-line option "rebuild-db" is doing the following tasks: ( from the constructor )

      $this->dropDb = new Doctrine_Task_DropDb($this->dispatcher);
      $this->buildAll = new Doctrine_Task_BuildAll($this->dispatcher);

      But the BuildAll tasks is executing three tasks including one which is regenerating the models. ( from the constructor )
      $this->models = new Doctrine_Task_GenerateModelsYaml($this->dispatcher);
      $this->createDb = new Doctrine_Task_CreateDb($this->dispatcher);
      $this->tables = new Doctrine_Task_CreateTables($this->dispatcher);

      My suggestion is to replace the build-all in the rebuild-db task with just the following. This would make more sense.

      $this->createDb = new Doctrine_Task_CreateDb($this->dispatcher);
      $this->tables = new Doctrine_Task_CreateTables($this->dispatcher);

        Activity

        There are no comments yet on this issue.

          People

          • Assignee:
            Jonathan H. Wage
            Reporter:
            Jerry Verhoef
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: