Swift 1.2 -> Swift 2 : <p>I'm coding an app for my Kids. I have background in Java but havn't professionally coded in a decade. I don't thoroughly understand how the following line works but it worked in Swift 1.2:</p>

<pre><code>leaderboardRequest.loadScoresWithCompletionHandler({ (scores:[AnyObject]!, error:NSError!) -&gt; Void in
            if (error != nil)
            {
</code></pre>

<p>I need help translating this into working Swift 2.0 code. Could someone please post a translation of working Swift 2.0 code for the following method:</p>

<pre><code>func getHighscores(leaderboardID: String) {

    let leaderboardRequest = GKLeaderboard() as GKLeaderboard!
    leaderboardRequest.identifier = leaderboardID

    if leaderboardRequest != nil
    {
        leaderboardRequest.loadScoresWithCompletionHandler({ (scores:[AnyObject]!, error:NSError!) -&gt; Void in
            if (error != nil)
            {
                //println("error in alltimeHighscoreForLevel")
                print(error.description)
                self.updateLocalHighscore()
            }
            else
            {
                if(leaderboardRequest != nil){
                    if(leaderboardRequest.scores != nil ) {
                        if(leaderboardRequest.scores!.count &gt; 0){
                            self.updateHighestForLevel(leaderboardRequest)

                        }
                    }
                }
            }
        })
    }
}
</code></pre>
