Fix local-clobbering iterators in phabricator/

Summary:
These are the issues identified by the linter in D2052. I don't think any cause bugs, but they are all reasonable errors to raise and the linter correctly
detected that they are suspicious.

Test Plan: Mostly inspection.

Reviewers: vrana, btrahan

Reviewed By: vrana

CC: aran, epriestley

Differential Revision: https://secure.phabricator.com/D2053
This commit is contained in:
epriestley
2012-03-29 13:24:06 -07:00
parent b6e0ca5ac6
commit 36ab0c3313
5 changed files with 20 additions and 20 deletions

View File

@@ -61,9 +61,9 @@ final class DiffusionHomeController extends DiffusionController {
$repository = new PhabricatorRepository();
$repositories = $repository->loadAll();
foreach ($repositories as $key => $repository) {
if (!$repository->isTracked()) {
unset($repositories[$key]);
foreach ($repositories as $key => $repo) {
if (!$repo->isTracked()) {
unset($repo[$key]);
}
}