Skip to content

Commit f79b959

Browse files
committed
clean code
1 parent b796f7f commit f79b959

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

Sources/WebViewLibrary/WebViewLibrary.swift

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import WebKit
55
public class WebViewLibrary: UIViewController, UIWebViewDelegate {
66

77
public var link: String
8-
public var isLinkTextfieldHidden: Bool?
8+
public var isLinkTextfieldHidden: Bool
99

1010
private let bigView: UIView = {
1111
let view = UIView()
@@ -71,10 +71,10 @@ public class WebViewLibrary: UIViewController, UIWebViewDelegate {
7171
webView.loadRequest(NSURLRequest(url: NSURL(string: link)! as URL) as URLRequest)
7272
webView.delegate = self
7373
linkTextField.text = link
74-
self.linkTextField.isHidden = isLinkTextfieldHidden ?? false
74+
self.linkTextField.isHidden = isLinkTextfieldHidden
7575
}
7676

77-
public init(link: String, isLinkTextfieldHidden: Bool? = false) {
77+
public init(link: String, isLinkTextfieldHidden: Bool = false) {
7878
self.link = link
7979
self.isLinkTextfieldHidden = isLinkTextfieldHidden
8080
super.init(nibName: nil, bundle: nil)

0 commit comments

Comments
 (0)