     }
 
     func webView(webView: UIWebView, didFailLoadWithError error: Error) {
-        theBool = true
+        isFinished = true
         webViewLoadsCount = 0
         UIApplication.shared.isNetworkActivityIndicatorVisible = false
     }

    }

    func finishAnimatingProgressBar() {
        self.theBool = true
    }

    func timerCallback() {
        // refer: http://stackoverflow.com/questions/28147096/progressbar-webview-in-swift
        if self.theBool {
            if self.progress >= 1 {
                UIView.animate(withDuration: 0.2, animations: { () -> Void in
                    self.alpha = 0

    }

    func inits() {
        startAnimatingProgressBar()
    }

    override func draw(_ rect: CGRect) {
