mirror of
https://github.com/elyby/accounts.git
synced 2024-11-27 01:02:06 +05:30
Fix manual-migrate command
This commit is contained in:
parent
dcb7345d58
commit
14661c2233
@ -24,7 +24,7 @@ class ManualMigrateController extends Controller {
|
|||||||
return (int)explode(':', $key)[2];
|
return (int)explode(':', $key)[2];
|
||||||
}, $keys);
|
}, $keys);
|
||||||
/** @var OauthSession[] $sessions */
|
/** @var OauthSession[] $sessions */
|
||||||
$sessions = OauthSession::find()->andWhere(['legacy_id' => $sessionsIds]);
|
$sessions = OauthSession::find()->andWhere(['legacy_id' => $sessionsIds])->all();
|
||||||
foreach ($sessions as $session) {
|
foreach ($sessions as $session) {
|
||||||
if (empty($session->scopes)) {
|
if (empty($session->scopes)) {
|
||||||
$session->scopes = Yii::$app->redis->smembers("oauth:sessions:{$session->legacy_id}:scopes");
|
$session->scopes = Yii::$app->redis->smembers("oauth:sessions:{$session->legacy_id}:scopes");
|
||||||
|
Loading…
Reference in New Issue
Block a user