Am 10.10.13 23:10, schrieb Ari Pringle:
> In src/OrgHeiglHybridAuth/Controller/IndexController.php:
> 
>> @@ -113,10 +113,10 @@ public function setUserWrapperFactory(UserWrapperFactory $factory)
>>       */
>>      public function loginAction()
>>      {
>> -        $config = $this->getServiceLocator()->get('Config');
>> -        $config = $config['OrgHeiglHybridAuth'];
>> +        $provider = $this->params()->fromRoute('provider');
>> +
> 
> Sounds good - I think the main reason I didn't do this was because I
> changed the route to /login/:provider[/:redirect] - so the provider
> isn't optional here (without overriding the route, anyway). I just liked
> the format of this URL better, but in the end it doesn't matter much and
> backwards compatibility is probably more important.
> 
> I could change it to /login/:redirect[/:provider], which would allow the
> provider to remain optional, so backwards compatibility could be
> retained. Do you think that is a good approach?
> 
Hi Ari.

Thanks for your input. I was thinking that over and I think I was a bit
fast there in the first place. As the URL should never be bookmarked or
stored but is generated "on the fly" we don't have to worry about BC
breaks here. Therefore it is perfectly OK to leave the loginAction as
you had it without the check for an existing provider. Therefore the
routing can stay the way you intended it. Actually I prefer the provider
before the base64-encoded redirect URL as it is more readable.

Therefore the BC-break issue is only relevant in the 'invode' method of
the viewHelper.

Regards.

Andreas


-- 
                                                              ,,,
                                                             (o o)
+---------------------------------------------------------ooO-(_)-Ooo-+
| Andreas Heigl                                                       |
| mailto:andreas@heigl.org                  N 50°22'59.5" E 08°23'58" |
| http://andreas.heigl.org                       http://hei.gl/wiFKy7 |
+---------------------------------------------------------------------+
| http://hei.gl/root-ca                                               |
+---------------------------------------------------------------------+