Merge pull request #122 from alexanderjarvis/master

Fix crash
This commit is contained in:
Robert Payne 2015-07-04 10:41:36 +12:00
commit 3d9a449e37
1 changed files with 3 additions and 3 deletions

View File

@ -107,11 +107,11 @@ private var labelKey = ""
private func descriptionForObject(object: AnyObject) -> String { private func descriptionForObject(object: AnyObject) -> String {
let pointerDescription = NSString(format: "%p", [object]) let pointerDescription = NSString(format: "%p", [object])
if let object = object as? View { if let object = object as? View {
return "<\(object.dynamicType):\(object.snp_label ?? pointerDescription)>" return "<\(object.dynamicType.description()):\(object.snp_label ?? pointerDescription)>"
} else if let object = object as? LayoutConstraint { } else if let object = object as? LayoutConstraint {
return "<\(object.dynamicType):\(object.snp_label ?? pointerDescription)>" return "<\(object.dynamicType.description()):\(object.snp_label ?? pointerDescription)>"
} }
return "<\(object.dynamicType):\(pointerDescription)>" return "<\(object.dynamicType.description()):\(pointerDescription)>"
} }
private extension NSLayoutRelation { private extension NSLayoutRelation {