Skip to content

Commit

Permalink
Switch to go-to-latest database migration configuration for simplicity (
Browse files Browse the repository at this point in the history
  • Loading branch information
alextselegidis committed Feb 23, 2022
1 parent e02d081 commit 6afef62
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion application/config/migration.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
| be upgraded / downgraded to.
|
*/
$config['migration_version'] = 21;
$config['migration_version'] = 0;


/*
Expand Down
2 changes: 1 addition & 1 deletion application/controllers/Backend.php
Original file line number Diff line number Diff line change
Expand Up @@ -351,7 +351,7 @@ public function update()
throw new Exception('You do not have the required privileges for this task!');
}

if ( ! $this->migration->current())
if ( ! $this->migration->latest())
{
throw new Exception($this->migration->error_string());
}
Expand Down
2 changes: 1 addition & 1 deletion application/controllers/Console.php
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ public function migrate($type = '')
show_error($this->migration->error_string());
}

if ($this->migration->current() === FALSE)
if ($this->migration->latest() === FALSE)
{
show_error($this->migration->error_string());
}
Expand Down
2 changes: 1 addition & 1 deletion application/controllers/Installation.php
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ public function ajax_install()
$admin = $this->input->post('admin');
$company = $this->input->post('company');

if ( ! $this->migration->current())
if ( ! $this->migration->latest())
{
throw new Exception($this->migration->error_string());
}
Expand Down

0 comments on commit 6afef62

Please sign in to comment.