Iterated elements are not used in forEach

Last modified: 03 December 2024

Reports forEach loops that do not use iterable values.

Example:

The quick fix introduces anonymous parameter in the forEach section: