Don't take screenshot on every warning or error.
Remove unused lines.