]> git.r.bdr.sh - rbdr/captura/blob - Captura/Data/CapturaRemoteFile+name.swift
feebdba201e7f04bc574ad7d2e33962a14ff1604
[rbdr/captura] / Captura / Data / CapturaRemoteFile+name.swift
1 import Foundation
2 extension CapturaRemoteFile {
3 var name: String {
4 let dateFormatter = DateFormatter()
5 dateFormatter.dateStyle = .medium
6 dateFormatter.timeStyle = .medium
7 dateFormatter.locale = Locale.current
8 if let timestamp {
9 return dateFormatter.string(from: timestamp).replacingOccurrences(of: ":", with: ".")
10 }
11 return "Unknown"
12 }
13 }