Fixing Double -> Int Bug