Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

iOS Build a Weather App with Swift Managing Complexity Methods with Closures

Ludwing Najera
Ludwing Najera
4,596 Points

Is this bad?

on 4:03 the line of code written on the bottom, "request', gives me a warning with a white circle in it and says: "Initialization of immutable variable 'request' was never used; consider replacing with assignment to '_' or removing it." I don't know what it means but it would be really helpful if i could at least know if its fine if I keep it like it is.

alt text

1 Answer

James Knight
James Knight
4,680 Points

Xcode throws these warnings often but I wouldn't worry to much, some times you may have a variable that was never mutated and Xcode may throw a warning asking you to change it to a constant. Search the apple documentation or the web for some more possible information on the warnings. hope this helps ! James