summaryrefslogtreecommitdiffstats
path: root/system/libraries
diff options
context:
space:
mode:
authorAhmad Anbar <aanbar@gmail.com>2014-04-01 00:40:37 +0200
committerAhmad Anbar <aanbar@gmail.com>2014-04-01 00:40:37 +0200
commit59739019bee552d6fa7e5c2bd5eddd932e44b045 (patch)
tree78959f62aa1dca4c5f365bb1f94d39733386f2f7 /system/libraries
parent9b19887fcc16a3bce52f2cbe84e98b8200bab23d (diff)
Fixed according to comment.
Diffstat (limited to 'system/libraries')
-rw-r--r--system/libraries/Migration.php9
1 files changed, 6 insertions, 3 deletions
diff --git a/system/libraries/Migration.php b/system/libraries/Migration.php
index 009b54fb4..71e0c6993 100644
--- a/system/libraries/Migration.php
+++ b/system/libraries/Migration.php
@@ -185,13 +185,16 @@ class CI_Migration {
public function version($target_version)
{
// Note: We use strings, so that timestamp versions work on 32-bit systems
- $current_version = $this->_get_version();
- $target_version = (string) $target_version;
+ $current_version = $this->_get_version();
- if ($this->_migration_type == 'sequential')
+ if ($this->_migration_type === 'sequential')
{
$target_version = str_pad($target_version, 3, '0', STR_PAD_LEFT);
}
+ else
+ {
+ $target_version = (string) $target_version;
+ }
$migrations = $this->find_migrations();