Skip to content

Commit

Permalink
Merge pull request #57 from andy1247008998/patch-1
Browse files Browse the repository at this point in the history
fabs is deprecated
  • Loading branch information
zenangst authored Jan 15, 2019
2 parents baddaf4 + 3c893c4 commit eb64f52
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Source/iOS/UIColor+Hue.swift
Original file line number Diff line number Diff line change
Expand Up @@ -96,8 +96,8 @@ public extension UIColor {
var result = false

if abs(bg[0] - fg[0]) > threshold || abs(bg[1] - fg[1]) > threshold || abs(bg[2] - fg[2]) > threshold {
if abs(bg[0] - bg[1]) < 0.03 && abs(bg[0] - bg[2]) < 0.03 {
if abs(fg[0] - fg[1]) < 0.03 && abs(fg[0] - fg[2]) < 0.03 {
if abs(bg[0] - bg[1]) < 0.03 && abs(bg[0] - bg[2]) < 0.03 {
if abs(fg[0] - fg[1]) < 0.03 && abs(fg[0] - fg[2]) < 0.03 {
result = false
}
}
Expand Down

0 comments on commit eb64f52

Please sign in to comment.