mirror of
https://github.com/Toxblh/MTMR.git
synced 2026-01-10 00:58:37 +00:00
fix drop MTMR without timeZone
This commit is contained in:
parent
732fd5c5b5
commit
238b15b6a4
@ -17,9 +17,9 @@
|
||||
<key>CFBundlePackageType</key>
|
||||
<string>APPL</string>
|
||||
<key>CFBundleShortVersionString</key>
|
||||
<string>0.19.2</string>
|
||||
<string>0.19.3</string>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>129</string>
|
||||
<string>130</string>
|
||||
<key>LSApplicationCategoryType</key>
|
||||
<string>public.app-category.utilities</string>
|
||||
<key>LSMinimumSystemVersion</key>
|
||||
|
||||
@ -325,7 +325,7 @@ class SupportedTypesHolder {
|
||||
enum ItemType: Decodable {
|
||||
case staticButton(title: String)
|
||||
case appleScriptTitledButton(source: SourceProtocol, refreshInterval: Double)
|
||||
case timeButton(formatTemplate: String, timeZone: String)
|
||||
case timeButton(formatTemplate: String, timeZone: String?)
|
||||
case battery()
|
||||
case dock()
|
||||
case volume()
|
||||
@ -394,7 +394,7 @@ enum ItemType: Decodable {
|
||||
case .timeButton:
|
||||
let template = try container.decodeIfPresent(String.self, forKey: .formatTemplate) ?? "HH:mm"
|
||||
let timeZone = try container.decodeIfPresent(String.self, forKey: .timeZone) ?? nil
|
||||
self = .timeButton(formatTemplate: template, timeZone: timeZone!)
|
||||
self = .timeButton(formatTemplate: template, timeZone: timeZone)
|
||||
|
||||
case .battery:
|
||||
self = .battery()
|
||||
|
||||
Loading…
Reference in New Issue
Block a user