Started working on history tracking
This commit is contained in:
21
App/Backend/History/HistoryItem.swift
Normal file
21
App/Backend/History/HistoryItem.swift
Normal file
@@ -0,0 +1,21 @@
|
||||
//
|
||||
// HistoryItem.swift
|
||||
// App
|
||||
//
|
||||
// Created by James Magahern on 8/14/20.
|
||||
//
|
||||
|
||||
import Foundation
|
||||
|
||||
struct HistoryItem: Hashable
|
||||
{
|
||||
var url: URL
|
||||
var title: String
|
||||
var lastVisited: Date
|
||||
|
||||
init(entity: HistoryItemEntity) {
|
||||
self.url = entity.url ?? URL(string: "about:blank")!
|
||||
self.lastVisited = entity.lastVisited ?? Date()
|
||||
self.title = entity.title ?? ""
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user