?
avatar photodude
photodude
6 Apr 2015

Is there a reason for the missing break statement at line 77 in bin\keychain.php at the case 'change':?
Seems like this would be (or could cause) an error by omission.

avatar photodude photodude - open - 6 Apr 2015
avatar joomla-cms-bot joomla-cms-bot - change - 6 Apr 2015
Labels Added: ?
avatar bertmert
bertmert - comment - 6 Apr 2015

@photodude Please let us know: Which file you are talking about? Too many lines 77 in Joomla... ;-)

avatar brianteeman brianteeman - change - 6 Apr 2015
Status New Information Required
avatar photodude
photodude - comment - 6 Apr 2015

@bertmert Sorry I forgot to add that...
the file is bin\keychain.php
line 77 is part of the switch
switch ($this->input->args[0])
and the case
case 'change':

avatar zero-24 zero-24 - change - 6 Apr 2015
Status Information Required New
avatar zero-24 zero-24 - change - 6 Apr 2015
Category External Library
avatar zero-24
zero-24 - comment - 6 Apr 2015

@photodude i have just open a PR against the uptream repo so the people there can decide see: joomla-framework/keychain#6

Thanks :+1:

avatar photodude
photodude - comment - 7 Apr 2015

@zero-24 I debated opening a PR for this, but I was unsure if it was intentional, and what logic could behind and intentional omission of a break at this point in the switch case. Hence opening an issue and posing the question.
If it was intentional, and not an omission, it should have been commented as such and likely should have been the first item in the switch-case. Otherwise I agree that a break statement is needed as you have done in the joomla-framework/keychain#6 PR.

Looking at the phpunit test for keychain at keychain/Tests/KeychainTest.php, I'm not sure that a "change" case is tested.

avatar zero-24
zero-24 - comment - 9 Apr 2015

Thanks @photodude but as this file is, as far i know. Never used with the main repo and we have the upstream dependency i will close here with the referr to the framework PR: joomla-framework/keychain#6

If the folks behind the framework decide to merge this i guess it will be synced it into the main repo.

Thank you!

avatar zero-24 zero-24 - change - 9 Apr 2015
Status New Closed
Closed_Date 0000-00-00 00:00:00 2015-04-09 12:28:25
avatar zero-24 zero-24 - close - 9 Apr 2015

Add a Comment

Login with GitHub to post a comment