Skip to content

Commit

Permalink
Fix isNan check
Browse files Browse the repository at this point in the history
  • Loading branch information
cemolcay committed Apr 3, 2019
1 parent 35f92ee commit 2bf6094
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions LiveFader/Source/LiveFader.swift
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ open class LiveFaderView: UIControl {
height: frame.size.height)
case (.fromMiddle, .vertical):
let isUp = value > ((maxValue - minValue) / 2.0)
let height = CGFloat(convert(
var height = CGFloat(convert(
value: value,
inRange: minValue...maxValue,
toRange: 0...Double(frame.size.height)))
Expand All @@ -137,7 +137,7 @@ open class LiveFaderView: UIControl {
}
case (.fromMiddle, .horizontal):
let isUp = value > ((maxValue - minValue) / 2.0)
let width = CGFloat(convert(
var width = CGFloat(convert(
value: value,
inRange: minValue...maxValue,
toRange: 0...Double(frame.size.width)))
Expand Down

0 comments on commit 2bf6094

Please sign in to comment.