Fix xcode warnings for shadowed variables