diff options
| author | Tristan Darricau <github@nicofuma.fr> | 2015-01-14 12:07:53 +0100 |
|---|---|---|
| committer | Tristan Darricau <github@nicofuma.fr> | 2015-01-14 12:16:24 +0100 |
| commit | ce47170c29f4bd7b6a9a4dc74f95be5b4241872d (patch) | |
| tree | cb838ecb6562829250c4e287be0a894b46616365 /phpBB/phpbb/db/migration/data/v30x | |
| parent | 4df125625c7df93a5c3727a3cfd9517df4ba0ba6 (diff) | |
| download | forums-ce47170c29f4bd7b6a9a4dc74f95be5b4241872d.tar forums-ce47170c29f4bd7b6a9a4dc74f95be5b4241872d.tar.gz forums-ce47170c29f4bd7b6a9a4dc74f95be5b4241872d.tar.bz2 forums-ce47170c29f4bd7b6a9a4dc74f95be5b4241872d.tar.xz forums-ce47170c29f4bd7b6a9a4dc74f95be5b4241872d.zip | |
[ticket/13489] Update migrations
PHPBB3-13489
Diffstat (limited to 'phpBB/phpbb/db/migration/data/v30x')
| -rw-r--r-- | phpBB/phpbb/db/migration/data/v30x/release_3_0_5_rc1.php | 22 |
1 files changed, 18 insertions, 4 deletions
diff --git a/phpBB/phpbb/db/migration/data/v30x/release_3_0_5_rc1.php b/phpBB/phpbb/db/migration/data/v30x/release_3_0_5_rc1.php index 2cc7786046..dc79071e16 100644 --- a/phpBB/phpbb/db/migration/data/v30x/release_3_0_5_rc1.php +++ b/phpBB/phpbb/db/migration/data/v30x/release_3_0_5_rc1.php @@ -13,8 +13,16 @@ namespace phpbb\db\migration\data\v30x; -class release_3_0_5_rc1 extends \phpbb\db\migration\migration +use Symfony\Component\DependencyInjection\ContainerAwareInterface; +use Symfony\Component\DependencyInjection\ContainerInterface; + +class release_3_0_5_rc1 extends \phpbb\db\migration\migration implements ContainerAwareInterface { + /** + * @var ContainerInterface + */ + protected $container; + public function effectively_installed() { return phpbb_version_compare($this->config['version'], '3.0.5-RC1', '>='); @@ -55,9 +63,7 @@ class release_3_0_5_rc1 extends \phpbb\db\migration\migration public function hash_old_passwords() { - global $phpbb_container; - - $passwords_manager = $phpbb_container->get('passwords.manager'); + $passwords_manager = $this->container->get('passwords.manager'); $sql = 'SELECT user_id, user_password FROM ' . $this->table_prefix . 'users WHERE user_pass_convert = 1'; @@ -130,4 +136,12 @@ class release_3_0_5_rc1 extends \phpbb\db\migration\migration } } } + + /** + * {@inheritdoc} + */ + public function setContainer(ContainerInterface $container = null) + { + $this->container = $container; + } } |
