Digital PCT265 defect MVAPCT-271 - greater than or equal to length fix
This commit is contained in:
parent
740c3eeb31
commit
8a7c07ecf2
@ -139,7 +139,7 @@ public final class Color: Codable {
|
|||||||
private func determineRGBA() throws {
|
private func determineRGBA() throws {
|
||||||
|
|
||||||
guard !hex.isEmpty else { return }
|
guard !hex.isEmpty else { return }
|
||||||
guard hex.count > 6 else {
|
guard hex.count >= 6 else {
|
||||||
throw ColorError.invalidHex(reason: "Invalid hex: \(hex)")
|
throw ColorError.invalidHex(reason: "Invalid hex: \(hex)")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user