added if statement to screenshots