php - Auth token resets after redirect in Silex -
using opauth signup through facebook , twitter, using this example
$app->on(opauthextension::event_success, function ($e) use ($app) { $userprovider = new userprovider($app); $userprovider->oauthlogin($e->getsubject()); //stores user , creates session //echo $app['security']->gettoken(); there works $e->setargument('result', $app->redirect($app['url_generator']->generate('_homepage'))); });
if call $app['security']->gettoken();
works on event dispatcher, after redirect falls down anon. user. login through form forks fine.
the problem in userproviderinterface. refreshuser method serched user wrong field.
Comments
Post a Comment