Vacuum before export
This commit is contained in:
@@ -2,7 +2,6 @@ import UIKit
|
|||||||
|
|
||||||
class TVCSettings: UITableViewController {
|
class TVCSettings: UITableViewController {
|
||||||
|
|
||||||
private let appDelegate = UIApplication.shared.delegate as! AppDelegate
|
|
||||||
@IBOutlet var vpnToggle: UISwitch!
|
@IBOutlet var vpnToggle: UISwitch!
|
||||||
@IBOutlet var cellDomainsIgnored: UITableViewCell!
|
@IBOutlet var cellDomainsIgnored: UITableViewCell!
|
||||||
@IBOutlet var cellDomainsBlocked: UITableViewCell!
|
@IBOutlet var cellDomainsBlocked: UITableViewCell!
|
||||||
@@ -71,6 +70,7 @@ class TVCSettings: UITableViewController {
|
|||||||
// MARK: - Privacy
|
// MARK: - Privacy
|
||||||
|
|
||||||
override func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) {
|
override func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) {
|
||||||
|
// FIXME: there is a lag between tap and open when run on device
|
||||||
if let cell = tableView.cellForRow(at: indexPath), cell === cellPrivacyAutoDelete {
|
if let cell = tableView.cellForRow(at: indexPath), cell === cellPrivacyAutoDelete {
|
||||||
let multiplier = [1, 7, 31]
|
let multiplier = [1, 7, 31]
|
||||||
let (one, two) = autoDeleteSelection(multiplier)
|
let (one, two) = autoDeleteSelection(multiplier)
|
||||||
@@ -117,6 +117,7 @@ class TVCSettings: UITableViewController {
|
|||||||
// MARK: - Advanced
|
// MARK: - Advanced
|
||||||
|
|
||||||
@IBAction private func exportDB() {
|
@IBAction private func exportDB() {
|
||||||
|
AppDB?.vacuum()
|
||||||
let sheet = UIActivityViewController(activityItems: [URL.internalDB()], applicationActivities: nil)
|
let sheet = UIActivityViewController(activityItems: [URL.internalDB()], applicationActivities: nil)
|
||||||
self.present(sheet, animated: true)
|
self.present(sheet, animated: true)
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user