Skip to content

Commit

Permalink
Do not load "migration" library initially in Manager
Browse files Browse the repository at this point in the history
  • Loading branch information
rougin committed Oct 19, 2024
1 parent b00b1c5 commit 9f25dac
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/Manager.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,6 @@ public function __construct(Controller $ci, $path)
{
$this->ci = $ci;

$this->ci->load->library('migration');

$this->path = $path;
}

Expand All @@ -41,6 +39,8 @@ public function __construct(Controller $ci, $path)
*/
public function getMigrations($reverse = false)
{
$this->ci->load->library('migration');

/** @var array<string, string> */
$items = $this->ci->migration->find_migrations();

Expand Down Expand Up @@ -140,6 +140,8 @@ public function getLastVersion()
*/
public function getLatestVersion()
{
$this->ci->load->library('migration');

/** @var array<string, string> */
$items = $this->ci->migration->find_migrations();

Expand Down

0 comments on commit 9f25dac

Please sign in to comment.