Project

General

Profile

Actions

Task #37502

closed

Remove commented-out code

Added by Oliver Klee over 12 years ago. Updated about 6 years ago.

Status:
Closed
Priority:
Should have
Assignee:
Category:
Code Cleanup
Target version:
-
Start date:
2012-05-26
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
6.0
PHP Version:
5.3
Tags:
Complexity:
Sprint Focus:

Description

Code can be commented out for several reasons:

1. debug code
2. code that does not work
3. old versions of the code
4. code that is part of some unfinished feature/change set and should not be used yet
5. code that has turned out to be not necessary after all

Commented-out code usually is not maintained, makes the code harder to read and cannot be unit-tested. It should be removed.

Concerning the separate reasons:

1. Debug modes should be enabled by settings, not be enabling/disabling the code.
2. Code that should not be executed should just get removed.
3. We have GIT for providing access to older versions of the code.
4. Unfinished feature should be in patches, branches and changesets.
5. Code that should not be executed should just get removed.

Actions

Also available in: Atom PDF