Skip to content

Commit

Permalink
Update ViewHelpers.swift
Browse files Browse the repository at this point in the history
  • Loading branch information
chili-ios authored Jan 24, 2019
1 parent d46d901 commit b183c30
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions CHICore/Classes/Utils/View/ViewHelpers.swift
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ extension UIView {
}
}

public static func viewFromXib<T: UIView>() -> T {
return UINib(nibName: String.className(T.self), bundle: nil).instantiate(withOwner: nil, options: nil)[0] as! T
public static func viewFromXib<T: UIView>(_ aBundle: Bundle? = nil) -> T {
return UINib(nibName: String.className(T.self), bundle: aBundle).instantiate(withOwner: nil, options: nil)[0] as! T
}
}

0 comments on commit b183c30

Please sign in to comment.